2

当我通过linkedin集成发送邀请时,出现以下错误

  "errorCode": 0,

  "message": "Internal API server error",

  "requestId": "3KLV53VUW0",

  "status": 500,

  "timestamp": 1365154932156

我正在发送这样的邀请请求

  NSURL *url = [NSURL URLWithString:@"http://api.linkedin.com/v1/people/~/mailbox"];

    OAMutableURLRequest *request =
    [[OAMutableURLRequest alloc] initWithURL:url
                                    consumer:oAuthLoginView.consumer
                                       token:oAuthLoginView.accessToken
                                    callback:nil
                           signatureProvider:nil];

 NSString *str = [NSString stringWithFormat:@"{\"recipients\":{\"values\": [{\"person\": {\"_path\": \"/people/6JmPthSfnJ\", }}]},\"subject\": \"Invitation to connect.\",\"body\": \"Say yes!\",\"item-content\":{\"invitation-request\":{\"connect-type\":\"friend\",\"authorization\":{ \"name\":\"NAME_SEARCH\",\"value\":\"i_QN\"}}}}"];


[request setHTTPMethod:@"POST"];

  [request setValue:@"application/json" forHTTPHeaderField:@"Content-Type"];

   [request setValue:@"json" forHTTPHeaderField:@"x-li-format"];

    [request setHTTPBodyWithString:str];




  NSString *str = [NSString stringWithFormat:@"{\"recipients\":{\"values\": [{\"person\": {\"_path\": \"/people/6JmPthSfnJ\", }}]},\"subject\": \"Invitation to connect.\",\"body\": \"Say yes!\",\"item-content\":{\"invitation-request\":{\"connect-type\":\"friend\",\"authorization\":{ \"name\":\"NAME_SEARCH\",\"value\":\"i_QN\"}}}}"];

任何人请帮帮我

提前致谢

4

0 回答 0