title: Set an NSDictionary in HTTPBody and send using POST method
body: <p>I want to call a web service with the <code>POST</code> method. I need to post a dictionary with a URL. My web service parameters are given below:</p>
  
  <pre><code>ConversationMessage {
         authorUserId (string, optional),
         subject (string, optional),
         hasAttachment (boolean, optional),
         conversationId (string, optional),
         attachment (DigitalAsset, optional),
         content (string, optional),
         title (string, optional),
         urgency (boolean, optional),
         searchable (Map[String,Object], optional)
  }
  
  DigitalAsset {
          id (string, optional),
          assetUrl (string, optional),
          assetContent (string, optional),
          thumbGenerated (boolean, optional),
          fileName (string, optional)
  }  
  
  Map[String,Object] {
          empty (boolean, optional)
  }
  </code></pre>
  
  <p><strong>Following is my request:</strong></p>
  
  <pre><code>    NSMutableArray *arr=[[NSMutableArray alloc]init];
      NSMutableDictionary *dict=[[NSMutableDictionary alloc]init];
      [dict setValue:@"test title" forKey:@"title"];
      [dict setValue:@"test message" forKey:@"content"];
      [dict setValue:@"0" forKey:@"urgency"];
  
      [arr addObject:[NSMutableDictionary dictionaryWithObject:dict forKey:@"ConversationMessage"]];
  
      NSMutableURLRequest *request = [[NSMutableURLRequest alloc] init] ;
      [request setURL:[NSURL URLWithString:strUrl]];
      [request setTimeoutInterval:10.0];
      [request setHTTPMethod:strMethod];
  
      NSString *boundary = @"---------------------------14737809831466499882746641449";
      NSString *contentType = [NSString stringWithFormat:@"multipart/form-data; boundary=%@",boundary];
      [request addValue:contentType forHTTPHeaderField: @"Content-Type"];
  
      NSMutableData *body=[[NSMutableData alloc]init];
      for (NSMutableDictionary *dict in array) {
  
        NSData *jsonData = [NSJSONSerialization dataWithJSONObject:dict options:0 error:NULL];
        [body appendData:jsonData];
  }
  
  [request setHTTPBody:body];
  </code></pre>
  
  <p>But I am getting the following error:</p>
  
  <p><strong>The server refused this request because the request entity is in a format not supported by the requested resource for the requested method</strong></p>