Skip to content

Releases: ServiceStack/ServiceStack.Swift

6.0.5

25 Nov 10:00
Compare
Choose a tag to compare

6.0.4

25 Nov 07:01
Compare
Choose a tag to compare

6.0.4

6.0.3

24 Nov 03:32
Compare
Choose a tag to compare

6.0.3

6.0.2

11 Nov 09:34
Compare
Choose a tag to compare

6.0.2

6.0.1

22 Oct 06:25
Compare
Choose a tag to compare

Added new sync and async file upload with Request APIs for POST and PUT HTTP Requests:

protocol ServiceClient {
    func postFileWithRequest<T: IReturn>(_ relativeUrl: String, request:T, fileName:String, data:Data, mimeType:String?, fieldName:String?) throws -> T.Return
    func postFileWithRequestAsync<T: IReturn>(_ relativeUrl: String, request:T, fileName:String, data:Data, mimeType:String?, fieldName:String?) async throws -> T.Return
    func postFileWithRequest<T: IReturn>(url:URL, request:T, fileName:String, data:Data, mimeType:String?, fieldName:String?) throws -> T.Return
    func postFileWithRequestAsync<T: IReturn>(url:URL, request:T, fileName:String, data:Data, mimeType:String?, fieldName:String?) async throws -> T.Return
    func postFilesWithRequest<T: IReturn & Codable>(request:T, files:[UploadFile]) throws -> T.Return
    func postFilesWithRequestAsync<T: IReturn & Codable>(request:T, files:[UploadFile]) async throws -> T.Return
    func postFilesWithRequest<T: IReturn>(url:URL, request:T, files:[UploadFile]) throws -> T.Return
    func postFilesWithRequestAsync<T: IReturn>(url:URL, request:T, files:[UploadFile]) async throws -> T.Return
    func putFileWithRequest<T: IReturn>(_ relativeUrl: String, request:T, fileName:String, data:Data, mimeType:String?, fieldName:String?) throws -> T.Return
    func putFileWithRequestAsync<T: IReturn>(_ relativeUrl: String, request:T, fileName:String, data:Data, mimeType:String?, fieldName:String?) async throws -> T.Return
    func putFileWithRequest<T: IReturn>(url:URL, request:T, fileName:String, data:Data, mimeType:String?, fieldName:String?) throws -> T.Return
    func putFileWithRequestAsync<T: IReturn>(url:URL, request:T, fileName:String, data:Data, mimeType:String?, fieldName:String?) async throws -> T.Return
    func putFilesWithRequest<T: IReturn & Codable>(request:T, files:[UploadFile]) throws -> T.Return
    func putFilesWithRequestAsync<T: IReturn & Codable>(request:T, files:[UploadFile]) async throws -> T.Return
    func putFilesWithRequest<T: IReturn>(url:URL, request:T, files:[UploadFile]) throws -> T.Return
    func putFilesWithRequestAsync<T: IReturn>(url:URL, request:T, files:[UploadFile]) async throws -> T.Return
    func sendFileWithRequest<T: IReturn>(_ req:inout URLRequest, request:T, fileName:String, data:Data, mimeType:String?, fieldName:String?) throws -> T.Return
    func sendFileWithRequestAsync<T: IReturn>(_ req:inout URLRequest, request:T, fileName:String, data:Data, mimeType:String?, fieldName:String?) async throws -> T.Return
    func sendFilesWithRequest<T: IReturn>(_ req:inout URLRequest, request:T, files:[UploadFile]) throws -> T.Return
    func sendFilesWithRequestAsync<T: IReturn>(_ req:inout URLRequest, request:T, files:[UploadFile]) async throws -> T.Return
}

6.0.0

22 Oct 06:11
Compare
Choose a tag to compare

The latest v6 Release is now dependency-free, where its PromiseKit async APIs have been replaced to use
Swift's native Concurrency support.

import ServiceStack

let client = JsonServiceClient(baseUrl:baseUrl)

Async

let request = Hello()
request.name = "World"

let response = try await client.postAsync(request)
print(response.result!)

Sync

let request = Hello()
request.name = "World"

let response = try client.post(request)
print(response.result!)

5.0.12

19 Mar 14:31
Compare
Choose a tag to compare
Unescape slahes in Inspect.dump

5.0.11

18 Mar 20:09
Compare
Choose a tag to compare
Update Library + Test DTOs

5.0.10

18 Mar 18:03
Compare
Choose a tag to compare
Fix creating request url

5.0.9

11 Mar 06:15
Compare
Choose a tag to compare
Add utils to convert from/to .NET DateTime,TimeSpan,byte[]