Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit abfe558

Browse files
Prep 1.0 (#37)
### Motivation Prep 1.0 - docs. ### Modifications See above. ### Result Updated for 1.0. ### Test Plan Previewed locally.
1 parent bdb9c8f commit abfe558

File tree

4 files changed

+8
-32
lines changed

4 files changed

+8
-32
lines changed

‎Package.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ let package = Package(
3636
dependencies: [
3737
.package(url: "https://github.com/apple/swift-nio", from: "2.58.0"),
3838
.package(url: "https://github.com/swift-server/async-http-client.git", from: "1.19.0"),
39-
.package(url: "https://github.com/apple/swift-openapi-runtime", exact: "1.0.0-alpha.1"),
39+
.package(url: "https://github.com/apple/swift-openapi-runtime", from: "1.0.0"),
4040
.package(url: "https://github.com/apple/swift-http-types", from: "1.0.0"),
4141
.package(url: "https://github.com/apple/swift-docc-plugin", from: "1.0.0"),
4242
],

‎README.md

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# AsyncHTTPClient Transport for Swift OpenAPI Generator
22

33
[![](https://img.shields.io/badge/docc-read_documentation-blue)](https://swiftpackageindex.com/swift-server/swift-openapi-async-http-client/documentation)
4+
[![](https://img.shields.io/github/v/release/swift-server/swift-openapi-async-http-client)](https://github.com/swift-server/swift-openapi-async-http-client/releases)
45
[![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fswift-server%2Fswift-openapi-async-http-client%2Fbadge%3Ftype%3Dswift-versions)](https://swiftpackageindex.com/swift-server/swift-openapi-async-http-client)
56
[![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fswift-server%2Fswift-openapi-async-http-client%2Fbadge%3Ftype%3Dplatforms)](https://swiftpackageindex.com/swift-server/swift-openapi-async-http-client)
67

@@ -18,28 +19,19 @@ Use the transport with client code generated by [Swift OpenAPI Generator](https:
1819
Add the package dependency in your `Package.swift`:
1920

2021
```swift
21-
.package(
22-
url: "https://github.com/swift-server/swift-openapi-async-http-client",
23-
exact: "1.0.0-alpha.1"
24-
),
22+
.package(url: "https://github.com/swift-server/swift-openapi-async-http-client", from: "1.0.0"),
2523
```
2624

27-
Note that this repository does not have a 1.0 tag yet, so the API is not stable.
28-
2925
Next, in your target, add `OpenAPIAsyncHTTPClient` to your dependencies:
3026

3127
```swift
3228
.target(name: "MyTarget", dependencies: [
3329
.product(name: "OpenAPIAsyncHTTPClient", package: "swift-openapi-async-http-client"),
34-
],
30+
]),
3531
```
3632

3733
Then, to get started, check out `AsyncHTTPClientTransport`.
3834

39-
## Reporting issues
40-
41-
Please report any issues related to this library in the [swift-openapi-generator](https://github.com/apple/swift-openapi-generator/issues) repository.
42-
4335
## Documentation
4436

4537
To learn more, check out the full [documentation](https://swiftpackageindex.com/swift-server/swift-openapi-async-http-client/documentation).

‎Sources/OpenAPIAsyncHTTPClient/AsyncHTTPClientTransport.swift

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -35,26 +35,19 @@ import protocol Foundation.LocalizedError
3535
///
3636
/// let transport = AsyncHTTPClientTransport()
3737
///
38-
/// Create the base URL of the server to call using your client. If the server
39-
/// URL was defined in the OpenAPI document, you find a generated method for it
40-
/// on the `Servers` type, for example:
41-
///
42-
/// let serverURL = try Servers.server1()
43-
///
4438
/// Instantiate the `Client` type generated by the Swift OpenAPI Generator for
4539
/// your provided OpenAPI document. For example:
4640
///
4741
/// let client = Client(
48-
/// serverURL: serverURL,
42+
/// serverURL: URL(string: "https://example.com")!,
4943
/// transport: transport
5044
/// )
5145
///
5246
/// Use the client to make HTTP calls defined in your OpenAPI document. For
5347
/// example, if the OpenAPI document contains an HTTP operation with
5448
/// the identifier `checkHealth`, call it from Swift with:
5549
///
56-
/// let response = try await client.checkHealth(.init())
57-
/// // ...
50+
/// let response = try await client.checkHealth()
5851
///
5952
/// ### Provide a custom Client
6053
///

‎Sources/OpenAPIAsyncHTTPClient/Documentation.docc/Documentation.md

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -18,28 +18,19 @@ Use the transport with client code generated by [Swift OpenAPI Generator](https:
1818
Add the package dependency in your `Package.swift`:
1919

2020
```swift
21-
.package(
22-
url: "https://github.com/swift-server/swift-openapi-async-http-client",
23-
exact: "1.0.0-alpha.1"
24-
),
21+
.package(url: "https://github.com/swift-server/swift-openapi-async-http-client", from: "1.0.0"),
2522
```
2623

27-
Note that this repository does not have a 1.0 tag yet, so the API is not stable.
28-
2924
Next, in your target, add `OpenAPIAsyncHTTPClient` to your dependencies:
3025

3126
```swift
3227
.target(name: "MyTarget", dependencies: [
3328
.product(name: "OpenAPIAsyncHTTPClient", package: "swift-openapi-async-http-client"),
34-
],
29+
]),
3530
```
3631

3732
Then, to get started, check out ``AsyncHTTPClientTransport``.
3833

39-
### Reporting issues
40-
41-
Please report any issues related to this library in the [swift-openapi-generator](https://github.com/apple/swift-openapi-generator/issues) repository.
42-
4334
## Topics
4435

4536
### Usage

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /