Skip to content

Commit

Permalink
docs: Added README."en".md translation via https://github.com/dephrai…
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Aug 9, 2024
1 parent 089b59a commit 0671b37
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions README.en.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ All APIs are written based on the OPenAPI specification, which means you can use

<https://api.tikhub.io/openapi.json>

当然,我们已经默认使用了Swagger UI来展示我们的API文档,你可以在网页上打开下面的链接,然后在网页上进行API Token的认证,随后点击任意端点然后点击`Try it out`You can test the endpoints you need. Most endpoints already carry default values ​​or demo values, which will better help you understand the required parameters of the call:
Of course, we have used Swagger UI by default to display our API documents. You can open the following link on the web page, then authenticate the API Token on the web page, then click on any endpoint and click`Try it out`You can test the endpoints you need. Most endpoints already carry default values ​​or demo values, which will better help you understand the required parameters of the call:

<https://api.tikhub.io>

Expand All @@ -58,15 +58,15 @@ The endpoints with the 🔒 icon in the interface document need to carry the API

> Generate API Token
The steps to obtain API Token are also very simple, you only need to log in to our user backend[Stay tuned](https://beta-web.tikhub.io/users/api_keys), then click on the left`API Keys`You can generate your own API Token, and at the same time, you can customize the permissions of the API Token (`Scopes`), you can also set the expiration date of the API Token (`Expire Date`), you can also manually temporarily close the API Token (`Status`)。
The steps to obtain API Token are also very simple. You only need to log in to our user backend.[Stay tuned](https://beta-web.tikhub.io/users/api_keys), then click on the left`API Keys`You can generate your own API Token, and at the same time, you can customize the permissions of the API Token (`Scopes`), you can also set the expiration date of the API Token (`Expire Date`), you can also manually temporarily close the API Token (`Status`)。

> Used on the API documentation web page
After you complete the above steps, you can copy your API Token, then return to our Swagger UI web page and click the green on the right side of the page`Authorize`, and then at the bottom of the pop-up window`Value`Paste the API Token in the input box to complete the authentication.
When you complete the above steps, you can copy your API Token, then return to our Swagger UI web page and click the green on the right side of the page`Authorize`, and then at the bottom of the pop-up window`Value`Paste the API Token in the input box to complete the authentication.

> Used in HTTP requests
If you want to carry the API Token in the HTTP request, please read the format below carefully, and you need to carry an API token in the request header.`Authorization`的字段,下面我将给出一个JSON作为header的示范:
If you want to carry the API Token in the HTTP request, please read the format below carefully, and you need to carry an API token in the request header.`Authorization`Field, below I will give an example of JSON as header:

{

Expand Down Expand Up @@ -206,7 +206,7 @@ if __name__ == "__main__":
print(video_data)
```

- We have used HTTPX to asynchronously encapsulate most endpoints. If your code is executed synchronously, you can use the following code to prevent asynchronous infection.
- 我们已经使用HTTPX的对大多数端点进行了异步封装,如果你的代码是同步执行的,你可以使用下面的代码防止异步传染。

```python
# 导入异步io库 | Import asyncio
Expand Down Expand Up @@ -250,7 +250,7 @@ if __name__ == "__main__":
print(video_data)
```

- Due to the limited chapters, the complete methods are not listed here. You can view the methods implemented in each attribute by viewing the source code. Each method is named according to the endpoint.`uri`来命名的,例如`/api/v1/douyin/app/v1/fetch_one_video`The method name is`fetch_one_video`, you can find the corresponding method according to the endpoint in the API document.
- Due to the limited chapters, the complete methods are not listed here. You can view the methods implemented in each attribute by viewing the source code. Each method is named according to the endpoint.`uri`to name, for example`/api/v1/douyin/app/v1/fetch_one_video`The method name is`fetch_one_video`, you can find the corresponding method according to the endpoint in the API document.
- And the parameters accepted by each method have been added`type hints`, you can understand the parameter types that the method needs to pass in by looking at the parameters of the method, which can better help you call the method.
- The document can automatically help you generate codes in different programming languages. Please check for details.[API Documentation](https://docs.tikhub.io/)
- Currently, the programming languages ​​that can automatically generate code are:
Expand Down

0 comments on commit 0671b37

Please sign in to comment.