-
Absolute path of the file you wish to upload.
Will only accept a filepath, no directories.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nonnull) NSString *filePath;
-
URL the request should be sent to.
Remember to append “?access_token=
” for Mapbox endpoints. Declaration
Objective-C
@property (nonatomic, copy, readonly, nonnull) NSString *url;
-
HTTP headers to include. If you provide
User-Agent
header using thisheaders
field, it is highly recommended to use the appropriate key fromHttpHeaders
set of constants. Duplicate headers (case insensitive) will result in an error.Declaration
Objective-C
@property (nonatomic, copy, nonnull) NSDictionary<NSString *, NSString *> *headers;
-
Metadata for the file, used for back-end file handling on Mapbox endpoints. Will be added to request as “attachments” if not empty. If you are uploading to a Mapbox backend, supply the appropriate information as a JSON string.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nonnull) NSString *metadata;
-
RFC6838 MediaType
Declaration
Objective-C
@property (nonatomic, copy, readonly, nonnull) NSString *mediaType;
-
Restrict the request to the specified network types. If none of the specified network types is available, the upload fails with a connection error.
Default is allowed on all network types
Declaration
Objective-C
@property (nonatomic, readonly) MBXNetworkRestriction networkRestriction;
-
Timeout defines how long, in seconds, the request is allowed to take in total (including connecting to the host).
Default is 0, meaning there is no timeout.
Declaration
Objective-C
@property (nonatomic, readonly) uint64_t timeout;