curl --request POST \
--url https://api.arg.ai/api/workspaces/{workspaceId}/files/share \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"path": "<string>"
}
'import requests
url = "https://api.arg.ai/api/workspaces/{workspaceId}/files/share"
payload = { "path": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({path: '<string>'})
};
fetch('https://api.arg.ai/api/workspaces/{workspaceId}/files/share', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{}{
"detail": "<string>"
}Create a share link
Mint a link to a file or folder. Sharing a file requires manage access to it.
curl --request POST \
--url https://api.arg.ai/api/workspaces/{workspaceId}/files/share \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"path": "<string>"
}
'import requests
url = "https://api.arg.ai/api/workspaces/{workspaceId}/files/share"
payload = { "path": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({path: '<string>'})
};
fetch('https://api.arg.ai/api/workspaces/{workspaceId}/files/share', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{}{
"detail": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Body
File or folder to share. The workspace root cannot be shared.
Hours until the link expires.
Number of downloads the link allows before it stops working.
Password required to open the link.
Serve the bytes as they are now instead of following later edits.
Let recipients edit the file.
Let recipients comment on the file.
Include the files this file references, so embeds load.
How include_references behaves. dynamic re-derives the list from the file's current contents on every access, so files it starts referencing later still load. snapshot fixes the list when the link is created. A link that allows editing is always snapshot; asking for dynamic alongside allow_edit is rejected.
dynamic, snapshot Response
Successful response
The response is of type object.