November 2018
Intermediate to advanced
404 pages
10h 16m
English
You can use a URLRequest instance to start an upload task:
var request = URLRequest(url: journalUrl)request.httpMethod = "POST"request.setValue("application/json", forHTTPHeaderField: "Content-Type")
URLRequest allows you to set the HTTP method (POST, PUT, GET, DELETE) using the httpMethod property of the request, as well as to set the values of any HTTP headers using the setValue(_:forHTTPHeaderField:) method.
Read now
Unlock full access