Skip to main content
POST
/
api
/
crates
/
packages
/
downloads
/crates/packages/downloads
curl --request POST \
  --url https://api.anysite.io/api/crates/packages/downloads \
  --header 'Content-Type: application/json' \
  --header 'access-token: <api-key>' \
  --data '
{
  "package": "<string>",
  "timeout": 300
}
'
[
  {
    "@type": "CratesVersionDownload",
    "version_id": 123,
    "download_count": 0,
    "date": ""
  }
]

Authorizations

access-token
string
header
required

API token from the dashboard

Headers

access-token
string
required

Body

application/json
package
string
required

Crate name (e.g. 'serde') or crates.io crate URL

Minimum string length: 1
Examples:

"serde"

"https://crates.io/crates/tokio"

timeout
integer
default:300

Max scrapping execution timeout (in seconds)

Required range: 20 <= x <= 1500

Response

Successful Response

@type
string
default:CratesVersionDownload
version_id
integer | null
download_count
integer
default:0
date
string
default:""