Skip to content

Commit 140194a

Browse files
committed
Update README
1 parent 0c6e919 commit 140194a

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

README.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
# api.video video uploader
44

5-
Typescript library to upload videos to api.video using delegated token (or usual access token) from front-end.
5+
Typescript library to upload videos to api.video using delegated upload token (or usual access token) from the front-end.
66

77
# Usage
88

@@ -78,18 +78,21 @@ Then, once the `window.onload` event has been trigered, create your player using
7878

7979
## Options
8080

81-
The upload is instanciated using an `options` object. Options to provide depend on the way you want to authenticate to the API: either using a delegated upload token (recommanded), or using a usual access token.
81+
The upload library is instanciated using an `options` object. Options to provide depend on the way you want to authenticate to the API: either using a delegated upload token (recommanded), or using a usual access token.
8282

83-
### Using a delegated token:
83+
### Using a delegated upload token (recommended):
84+
85+
Using delegated upload tokens for authentication is best options when uploading from the client side. To know more about delegated upload token, read the dedicated article on api.video's blog: [Delegated Uploads](https://api.video/blog/tutorials/delegated-uploads).
8486

8587

8688
| Option name | Mandatory | Type | Description |
8789
| ----------------------------: | --------- | ------ | ----------------- |
8890
| uploadToken | **yes** | string | your upload token |
8991
| _common options (see bellow)_ | | | |
9092

93+
### Using an access token (discouraged):
9194

92-
### Using an access token:
95+
**Warning**: be aware that exposing your access token client-side can lead to huge security issues. Use this method only if you know what you're doing :).
9396

9497

9598
| Option name | Mandatory | Type | Description |
@@ -104,7 +107,7 @@ The upload is instanciated using an `options` object. Options to provide depend
104107

105108
| Option name | Mandatory | Type | Description |
106109
| ----------: | --------- | ------ | ----------------------------------------------------- |
107-
| file | yes | File | the file you want to upload |
110+
| file | **yes** | File | the file you want to upload |
108111
| chunkSize | no | number | number of bytes of each upload chunk (default: 1MB) |
109112
| apiHost | no | string | api.video host (default: ws.api.video) |
110113
| retries | no | number | number of retries when an API call fails (default: 5) |

0 commit comments

Comments
 (0)