Closed Bleyddyn closed 9 years ago
The code is done and in the 0.3.1b release (https://github.com/sixones/vitality/releases/tag/v0.3.1b). I tested the server monitor call by replacing the URL with my own web server, but I'm not sure how to test anything else. With all of the other CCP calls going through https, I don't think I'll be able to see headers with wireshark or similar tools.
You can probably test this with Charles Proxy. http://www.charlesproxy.com
CCP requests that all API calls have a User-Agent set in case they need to contact a developer about issues. See https://developers.testeveonline.com/resource/xml-api
Code like this can be used to do that: NSString* userAgent = @"My Cool User Agent"; NSURL* url = [NSURL URLWithString:@"http://whatsmyuseragent.com/"]; NSMutableURLRequest* request = [[[NSMutableURLRequest alloc] initWithURL:url] autorelease]; [request addValue:userAgent forHTTPHeaderField:@"User-Agent"];
Our User-Agent could be something like: @"Vitality v0.3 (https://github.com/sixones/vitality)"