Search code examples
iosrestkit

Retrieving HTTPBody from RestKit response


I am using the postObject and putObject functions of restKit. I need to extract some info from the payload and put it in the header before sending it out.. any suggestions on how I can do that?

ex:

[[RKObjectManager sharedManager] postObject:object path:OBJECT parameters:nil success:success failure:failure];

I will probably have to do something like

// Create Payload for this request
// update header accordingly
// call postObject

I would like to avoid throwing away existing code..


Solution

  • I was able to do this by using all the params that I was passing before making the RK request.