HTTP Verbs

The API attempts to be as RESTful as possible by using appropriate HTTP Verbs for each action, such as:

VerbDescription
OPTIONSUsed to retrieve the available HTTP verbs, name, description, input format (parsers) and output format (renderers) for a particular resource.
GETUsed for retrieving resources.
PUTUsed for replacing resources or collections.
POSTUsed for creating resources.
PATCHUsed for partially updating an existing resource with one or more changes. For example, changing the description on a repository resource is a PATCH.
DELETEUsed to delete specific resources.

As described above, the OPTIONS request will show the available HTTP verbs for a resource, in addition to some details about the resource itself. Let's see it in action:

curl -i -X OPTIONS  https://api.cloudsmith.io/user/self/

HTTP/1.0 200 OK
Allow: GET, OPTIONS
Content-Type: application/json
Date: Sun, 29 Jan 2017 18:02:54 GMT

{
  "name": "User Who Am I",
  "description": "View for showing the current user details.",
  "renders": ["application/json"],
  "parses": ["application/json"]
}

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)