本文為您提供了Objective-C語言版本的提交查詢接口對接DEMO示例
NSString *host = @"api.ihuyi.com";
NSString *path = "/idcard/entmark/Submit.json";
NSString *method = @"POST";
NSString *querys = @"?account=xxxxxxxx&password=xxxxxxxxx&ent_name=上海************有限公司&ent_code=913******&organization_code=403925******®_no=403925******&begin_date=2025-01-01&end_date=2025-01-01&int_category=1&application_number=403925******&page_index=1&page_size=20&time=1623643787&";
NSString *url = [NSString stringWithFormat:@"%@%@%@", host, path , querys];
NSString *bodys = @"";
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString: url] cachePolicy:1 timeoutInterval: 5];
request.HTTPMethod = method;
[request setValue:@"application/x-www-form-urlencoded" forHTTPHeaderField:@"Content-Type"];
NSURLSession *requestSession = [NSURLSession sessionWithConfiguration:[NSURLSessionConfiguration defaultSessionConfiguration]];
NSURLSessionDataTask *task = [requestSession dataTaskWithRequest:request
completionHandler:^(NSData * _Nullable body , NSURLResponse * _Nullable response, NSError * _Nullable error) {
NSLog(@"Response object: %@" , response);
NSString *bodyString = [[NSString alloc] initWithData:body encoding:NSUTF8StringEncoding];
//打印body內容
NSLog(@"Response body: %@" , bodyString);
}];
[task resume];
國內專業(yè)互聯(lián)網團隊
21年行業(yè)經驗
7x24小時售后支持
豐富的行業(yè)經驗
Copyright ? 2004-2025 上海思銳信息技術有限公司 All rights reserved. 滬ICP備07035915號-15 電信增值業(yè)務許可證:B2-20160082
服務熱線:
4008 808 898
服務熱線(工作時間):
4008 808 898
業(yè)務咨詢(非工作時間):
售后咨詢(非工作時間):
驗證碼已發(fā)送到您的手機,請查收!
輸入驗證碼后,點擊“開通體驗賬戶”按鈕可立即開通體驗賬戶。