Skip to content

Commit 9a85881

Browse files
Merge pull request #80 from apivideo/documentation-swift-uploader
README to documentation synchro
2 parents 35aa78c + 012f73f commit 9a85881

File tree

2 files changed

+82
-38
lines changed

2 files changed

+82
-38
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Create documentation PR
2+
on:
3+
# Trigger the workflow on pull requests targeting the main branch
4+
pull_request:
5+
types: [assigned, unassigned, opened, reopened, synchronize, edited, labeled, unlabeled, edited, closed]
6+
branches:
7+
- main
8+
9+
jobs:
10+
create_documentation_pr:
11+
if: github.event.action != 'closed'
12+
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Check out current repository code
17+
uses: actions/checkout@v2
18+
19+
- name: Create the documentation pull request
20+
uses: apivideo/api.video-create-readme-file-pull-request-action@main
21+
with:
22+
source-file-path: "README.md"
23+
destination-repository: apivideo/api.video-documentation
24+
destination-path: sdks/vod
25+
destination-filename: apivideo-swift-uploader.md
26+
pat: "${{ secrets.PAT }}"
27+

README.md

Lines changed: 55 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,57 @@
1+
<!--<documentation_excluded>-->
12
[![badge](https://img.shields.io/twitter/follow/api_video?style=social)](https://twitter.com/intent/follow?screen_name=api_video) &nbsp; [![badge](https://img.shields.io/github/stars/apivideo/api.video-swift-uploader?style=social)]() &nbsp; [![badge](https://img.shields.io/discourse/topics?server=https%3A%2F%2Fcommunity.api.video)](https://community.api.video)
23
![](https://github.com/apivideo/.github/blob/main/assets/apivideo_banner.png)
34
<h1 align="center">api.video Swift uploader</h1>
45

56
[api.video](https://api.video) is the video infrastructure for product builders. Lightning fast video APIs for integrating, scaling, and managing on-demand & low latency live streaming features in your app.
67

7-
# Table of contents
8+
## Table of contents
89

10+
- [Table of contents](#table-of-contents)
911
- [Project description](#project-description)
1012
- [Getting started](#getting-started)
1113
- [Installation](#installation)
1214
- [Carthage](#carthage)
13-
- [CocoaPods](#cocoaPods)
15+
- [CocoaPods](#cocoapods)
1416
- [Code sample](#code-sample)
1517
- [Documentation](#documentation)
1618
- [API Endpoints](#api-endpoints)
17-
- [VideosAPI](#VideosAPI)
19+
- [VideosAPI](#videosapi)
20+
- [Retrieve an instance of VideosAPI:](#retrieve-an-instance-of-videosapi)
21+
- [Endpoints](#endpoints)
1822
- [Models](#models)
19-
- [Authorization](#documentation-for-authorization)
23+
- [Documentation for Authorization](#documentation-for-authorization)
2024
- [API key](#api-key)
2125
- [Public endpoints](#public-endpoints)
22-
- [Have you gotten use from this API client?](#have-you-gotten-use-from-this-api-client)
26+
- [Have you gotten use from this API client?](#have-you-gotten-use-from-this-api-client)
2327
- [Contribution](#contribution)
2428

25-
# Project description
29+
<!--</documentation_excluded>-->
30+
<!--<documentation_only>
31+
---
32+
title: api.video Swift video uploader
33+
meta:
34+
description: The official api.video Swift video uploader for api.video. [api.video](https://api.video/) is the video infrastructure for product builders. Lightning fast video APIs for integrating, scaling, and managing on-demand & low latency live streaming features in your app.
35+
---
2636
27-
api.video's Swift for iOS, macOS and tvOS uploads videos to api.video using delegated upload token or API Key.
37+
# api.video Swift video uploader
38+
39+
[api.video](https://api.video/) is the video infrastructure for product builders. Lightning fast video APIs for integrating, scaling, and managing on-demand & low latency live streaming features in your app.
40+
41+
</documentation_only>-->
42+
## Project description
43+
44+
api.video's Swift uploader for iOS, macOS and tvOS uploads videos to api.video using delegated upload token or API Key.
2845

2946
It allows you to upload videos in two ways:
3047
- standard upload: to send a whole video file in one go
3148
- progressive upload: to send a video file by chunks, without needing to know the final size of the video file
3249

33-
# Getting started
50+
## Getting started
3451

35-
## Installation
52+
### Installation
3653

37-
### Carthage
54+
#### Carthage
3855

3956
Specify it in your `Cartfile`:
4057

@@ -44,13 +61,13 @@ github "apivideo/api.video-swift-uploader" ~> 1.2.2
4461

4562
Run `carthage update`
4663

47-
### CocoaPods
64+
#### CocoaPods
4865

4966
Add `pod 'ApiVideoUploader', '1.2.2'` in your `Podfile`
5067

5168
Run `pod install`
5269

53-
## Code sample
70+
### Code sample
5471

5572
Please follow the [installation](#installation) instruction and execute the following Swift code:
5673
```swift
@@ -69,66 +86,66 @@ try VideosAPI.uploadWithUploadToken(token: "MY_VIDEO_TOKEN", file: url) { video,
6986
}
7087
```
7188

72-
# Documentation
89+
## Documentation
7390

74-
## API Endpoints
91+
### API Endpoints
7592

7693
All URIs are relative to *https://ws.api.video*
7794

7895

79-
### VideosAPI
96+
#### VideosAPI
8097

81-
#### Retrieve an instance of VideosAPI:
98+
##### Retrieve an instance of VideosAPI:
8299

83100
```swift
84101
VideosAPI
85102
```
86103

87-
#### Endpoints
104+
##### Endpoints
88105

89106
Method | HTTP request | Description
90107
------------- | ------------- | -------------
91-
[**upload**](docs/VideosAPI.md#upload) | **POST** /videos/{videoId}/source | Upload a video
92-
[**uploadWithUploadToken**](docs/VideosAPI.md#uploadWithUploadToken) | **POST** /upload | Upload with an delegated upload token
108+
[**upload**](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/VideosAPI.md#upload) | **POST** /videos/{videoId}/source | Upload a video
109+
[**uploadWithUploadToken**](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/VideosAPI.md#uploadWithUploadToken) | **POST** /upload | Upload with an delegated upload token
93110

94111

95112

96-
## Models
113+
### Models
97114

98-
- [AccessToken](docs/AccessToken.md)
99-
- [AdditionalBadRequestErrors](docs/AdditionalBadRequestErrors.md)
100-
- [AuthenticatePayload](docs/AuthenticatePayload.md)
101-
- [BadRequest](docs/BadRequest.md)
102-
- [Metadata](docs/Metadata.md)
103-
- [NotFound](docs/NotFound.md)
104-
- [RefreshTokenPayload](docs/RefreshTokenPayload.md)
105-
- [Video](docs/Video.md)
106-
- [VideoAssets](docs/VideoAssets.md)
107-
- [VideoSource](docs/VideoSource.md)
108-
- [VideoSourceLiveStream](docs/VideoSourceLiveStream.md)
109-
- [VideoSourceLiveStreamLink](docs/VideoSourceLiveStreamLink.md)
115+
- [AccessToken](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/AccessToken.md)
116+
- [AdditionalBadRequestErrors](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/AdditionalBadRequestErrors.md)
117+
- [AuthenticatePayload](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/AuthenticatePayload.md)
118+
- [BadRequest](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/BadRequest.md)
119+
- [Metadata](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/Metadata.md)
120+
- [NotFound](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/NotFound.md)
121+
- [RefreshTokenPayload](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/RefreshTokenPayload.md)
122+
- [Video](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/Video.md)
123+
- [VideoAssets](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/VideoAssets.md)
124+
- [VideoSource](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/VideoSource.md)
125+
- [VideoSourceLiveStream](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/VideoSourceLiveStream.md)
126+
- [VideoSourceLiveStreamLink](https://github.com/apivideo/api.video-swift-uploader/blob/main/docs/VideoSourceLiveStreamLink.md)
110127

111128

112-
## Documentation for Authorization
129+
### Documentation for Authorization
113130

114-
### API key
131+
#### API key
115132

116133
Most endpoints required to be authenticated using the API key mechanism described in our [documentation](https://docs.api.video/reference#authentication).
117134

118135
You must NOT store your API key in your application code to prevent your API key from being exposed in your source code.
119136
Only the [Public endpoints](#public-endpoints) can be called without authentication.
120137
In the case, you want to call an endpoint that requires authentication, you will have to use a backend server. See [Security best practices](https://docs.api.video/sdks/security) for more details.
121138

122-
### Public endpoints
139+
#### Public endpoints
123140

124141
Some endpoints don't require authentication. These one can be called without setting `ApiVideoUploader.apiKey`.
125142

126-
## Have you gotten use from this API client?
143+
### Have you gotten use from this API client?
127144

128145
Please take a moment to leave a star on the client ⭐
129146

130147
This helps other users to find the clients and also helps us understand which clients are most popular. Thank you!
131148

132-
# Contribution
149+
## Contribution
133150

134-
Since this API client is generated from an OpenAPI description, we cannot accept pull requests made directly to the repository. If you want to contribute, you can open a pull request on the repository of our [client generator](https://github.com/apivideo/api-client-generator). Otherwise, you can also simply open an issue detailing your need on this repository.
151+
Since this API client is generated from an OpenAPI description, we cannot accept pull requests made directly to the repository. If you want to contribute, you can open a pull request on the repository of our [client generator](https://github.com/apivideo/api-client-generator). Otherwise, you can also simply open an issue detailing your need on this repository.

0 commit comments

Comments
 (0)