Updated the README and the Documentation catalog documentation in the library target.
This commit is contained in:
@@ -4,23 +4,13 @@ A Swift client library for the App Store Connect API, generated from the officia
|
||||
|
||||
## Overview
|
||||
|
||||
``ASConnectService`` provides a type-safe, Swift-native interface to Apple's App Store Connect API. This package enables developers to programmatically interact with App Store Connect services for managing apps, builds, reviews, sales reports, and more.
|
||||
`ASConnectService` provides a type-safe, Swift-native interface to Apple's App Store Connect API. This package enables developers to programmatically interact with App Store Connect services for managing apps, builds, reviews, sales reports, and more.
|
||||
|
||||
The library is automatically generated from the official App Store Connect API OpenAPI specification using Apple's `swift-openapi-generator`, ensuring complete API coverage and type safety.
|
||||
|
||||
## Key Features
|
||||
|
||||
- **Type-Safe API**: Fully typed requests and responses based on the OpenAPI specification
|
||||
- **Async/Await Support**: Modern Swift concurrency with `async`/`await`
|
||||
- **Cross-Platform**: Supports iOS, macOS, tvOS, visionOS, and watchOS
|
||||
- **Automatic Generation**: Code is generated from the official API specification
|
||||
- **Comprehensive Coverage**: Access to all App Store Connect API endpoints
|
||||
The library is automatically generated from the official App Store Connect API OpenAPI specification using Apple's [swift-openapi-generator](https://github.com/apple/swift-openapi-generator), ensuring complete API coverage and type safety.
|
||||
|
||||
## Installation
|
||||
|
||||
### Swift Package Manager
|
||||
|
||||
Add ``ASConnectService`` as a dependency in your `Package.swift` file:
|
||||
Add `ASConnectService` as a dependency in your `Package.swift` file:
|
||||
|
||||
```swift
|
||||
dependencies: [
|
||||
@@ -39,23 +29,11 @@ Then add it to your target dependencies:
|
||||
)
|
||||
```
|
||||
|
||||
## Basic Usage
|
||||
## Usage
|
||||
|
||||
```swift
|
||||
import ASConnectService
|
||||
import OpenAPIURLSession
|
||||
### Creating a Client
|
||||
|
||||
// Create a client with your API key
|
||||
let client = Client(
|
||||
serverURL: try Servers.server1(),
|
||||
transport: URLSessionTransport()
|
||||
)
|
||||
|
||||
// Make API calls
|
||||
let apps = try await client.apps_get()
|
||||
```
|
||||
|
||||
## Authentication
|
||||
Create a `Client` instance by providing a server URL and transport. Use `BearerAuthMiddleware` to authenticate requests with a JSON Web Token (JWT).
|
||||
|
||||
The App Store Connect API requires authentication using API keys. You'll need to:
|
||||
|
||||
@@ -70,11 +48,19 @@ import OpenAPIURLSession
|
||||
let client = Client(
|
||||
serverURL: try Servers.server1(),
|
||||
transport: URLSessionTransport(),
|
||||
middlewares: [BearerAuthMiddleware(token: yourJWTToken)]
|
||||
middlewares: [
|
||||
BearerAuthMiddleware(token: yourJWTToken)
|
||||
]
|
||||
)
|
||||
```
|
||||
|
||||
The `BearerAuthMiddleware` automatically injects the `Authorization` header with the Bearer token into every outgoing request.
|
||||
### Making API Calls
|
||||
|
||||
The `Client` conforms to `APIProtocol`, which defines a method for every endpoint in the App Store Connect API. Each method accepts an `Input` value and returns an `Output` value with the response.
|
||||
|
||||
```swift
|
||||
let response = try await client.appsGetCollection(.init())
|
||||
```
|
||||
|
||||
## Supported Platforms
|
||||
|
||||
@@ -120,20 +106,8 @@ make doc-preview
|
||||
|
||||
## License
|
||||
|
||||
Licensed under the Apache License, Version 2.0. See LICENSE file for details.
|
||||
Licensed under the Apache License, Version 2.0. See [LICENSE](LICENSE) for details.
|
||||
|
||||
## Contributing
|
||||
|
||||
See CONTRIBUTORS file for the list of project authors.
|
||||
|
||||
## API Coverage
|
||||
|
||||
The package provides access to all App Store Connect API endpoints including:
|
||||
|
||||
- Apps and app management
|
||||
- Builds and beta testing
|
||||
- App Store reviews and ratings
|
||||
- Sales and financial reports
|
||||
- User and role management
|
||||
- In-app purchases and subscriptions
|
||||
- And many more...
|
||||
See [CONTRIBUTORS](CONTRIBUTORS) for the list of project authors.
|
||||
|
||||
Reference in New Issue
Block a user