Query Parameters

Many of the API resource endpoints take optional parameters, such as for filtering, in addition to standard ones for versioning and pagination. For GET requests, any parameter not specified as part of the URI path can be specified as an HTTP query string parameter. For example, to retrieve packages for a repository that are currently awaiting synchronisation:

curl -i https://api.cloudsmith.io/package/example/repo/?status=awaiting_sync

For DELETE, PATCH, POST and PUT requests, any optional parameters should be specified within the body of the request, encoded as JSON with a Content-Type header specifying a value of application/json. For example, to delete packages for a repository that are currently awaiting synchronisation:

curl -i -H "Content-Type: application/json" -d '{"status": "awaiting_sync"}' -X DELETE https://api.cloudsmith.io/package/example/repo/

Cloudsmith is the new standard in Package / Artifact Management and Software Distribution

With support for all major package formats, you can trust us to manage your software supply chain.


Start My Free Trial Now
Cookie Declaration (Manage Cookies)