【发布时间】:2022-01-06 05:01:50
【问题描述】:
我需要向 api 发送 cURL 请求,但我没有正确理解文档。第一次使用 cURL。这是发送请求的详细信息。
# Steps to send request
# First get JSON Web Token
# Please get your Client Id and Client Secret from https://dashboard.groupdocs.cloud/applications.
# Kindly place Client Id in "client_id" and Client Secret in "client_secret" argument.
curl -v "https://api.groupdocs.cloud/connect/token" \
-X POST \
-d "grant_type#client_credentials&client_id#xxxx&client_secret#xxxx" \
-H "Content-Type: application/x-www-form-urlencoded" \
-H "Accept: application/json"
$ cURL example to join several documents into one
curl -v "https://api.groupdocs.cloud/v1.0/parser/text" \
-X POST \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "Authorization: Bearer
<jwt token>" \
-d "{
"FileInfo": {
"FilePath": "words\docx\document.docx",
}
}"
这就是响应的方式
{
"text": "First Page\r\r\f"
}
【问题讨论】:
标签: json flutter rest dart curl