Metadata-Version: 2.1
Name: vultr-python-client
Version: 1.0.2
Summary: Vultr API
Home-page: 
Author: OpenAPI Generator community
Author-email: opensource@vultr.com
Keywords: OpenAPI,OpenAPI-Generator,Vultr API
Requires-Python: >=3.7

    # Introduction  The Vultr API v2 is a set of HTTP endpoints that adhere to RESTful design principles and CRUD actions with predictable URIs. It uses standard HTTP response codes, authentication, and verbs. The API has consistent and well-formed JSON requests and responses with cursor-based pagination to simplify list handling. Error messages are descriptive and easy to understand. All functions of the Vultr customer portal are accessible via the API, enabling you to script complex unattended scenarios with any tool fluent in HTTP.  ## Requests  Communicate with the API by making an HTTP request at the correct endpoint. The chosen method determines the action taken.  | Method | Usage | | ------ | ------------- | | DELETE | Use the DELETE method to destroy a resource in your account. If it is not found, the operation will return a 4xx error and an appropriate message. | | GET | To retrieve information about a resource, use the GET method. The data is returned as a JSON object. GET methods are read-only and do not affect any resources. | | PATCH | Some resources support partial modification with PATCH, which modifies specific attributes without updating the entire object representation. | | POST | Issue a POST method to create a new object. Include all needed attributes in the request body encoded as JSON. | | PUT | Use the PUT method to update information about a resource. PUT will set new values on the item without regard to their current values. |  **Rate Limit:** Vultr safeguards the API against bursts of incoming traffic based on the request&#x27;s IP address to ensure stability for all users. If your application sends more than 30 requests per second, the API may return HTTP status code 429.  ## Response Codes  We use standard HTTP response codes to show the success or failure of requests. Response codes in the 2xx range indicate success, while codes in the 4xx range indicate an error, such as an authorization failure or a malformed request. All 4xx errors will return a JSON response object with an &#x60;error&#x60; attribute explaining the error. Codes in the 5xx range indicate a server-side problem preventing Vultr from fulfilling your request.  | Response | Description | | ------ | ------------- | | 200 OK | The response contains your requested information. | | 201 Created | Your request was accepted. The resource was created. | | 202 Accepted | Your request was accepted. The resource was created or updated. | | 204 No Content | Your request succeeded, there is no additional information returned. | | 400 Bad Request | Your request was malformed. | | 401 Unauthorized | You did not supply valid authentication credentials. | | 403 Forbidden | You are not allowed to perform that action. | | 404 Not Found | No results were found for your request. | | 429 Too Many Requests | Your request exceeded the API rate limit. | | 500 Internal Server Error | We were unable to perform the request due to server-side problems. |  ## Meta and Pagination  Many API calls will return a &#x60;meta&#x60; object with paging information.  ### Definitions  | Term | Description | | ------ | ------------- | | **List** | The items returned from the database for your request (not necessarily shown in a single response depending on the **cursor** size). | | **Page** | A subset of the full **list** of items. Choose the size of a **page** with the &#x60;per_page&#x60; parameter. | | **Total** | The &#x60;total&#x60; attribute indicates the number of items in the full **list**.| | **Cursor** | Use the &#x60;cursor&#x60; query parameter to select a next or previous **page**. | | **Next** &amp; **Prev** | Use the &#x60;next&#x60; and &#x60;prev&#x60; attributes of the &#x60;links&#x60; meta object as &#x60;cursor&#x60; values. |  ### How to use Paging  If your result **list** total exceeds the default **cursor** size (the default depends on the route, but is usually 100 records) or the value defined by the &#x60;per_page&#x60; query param (when present) the response will be returned to you paginated.  ### Paging Example  &gt; These examples have abbreviated attributes and sample values. Your actual &#x60;cursor&#x60; values will be encoded alphanumeric strings.  To return a **page** with the first two plans in the List:      curl \&quot;https://api.vultr.com/v2/plans?per_page&#x3D;2\&quot; \       -X GET \       -H \&quot;Authorization: Bearer ${VULTR_API_KEY}\&quot;  The API returns an object similar to this:      {         \&quot;plans\&quot;: [             {                 \&quot;id\&quot;: \&quot;vc2-1c-2gb\&quot;,                 \&quot;vcpu_count\&quot;: 1,                 \&quot;ram\&quot;: 2048,                 \&quot;locations\&quot;: []             },             {                 \&quot;id\&quot;: \&quot;vc2-24c-97gb\&quot;,                 \&quot;vcpu_count\&quot;: 24,                 \&quot;ram\&quot;: 98304,                 \&quot;locations\&quot;: []             }         ],         \&quot;meta\&quot;: {             \&quot;total\&quot;: 19,             \&quot;links\&quot;: {                 \&quot;next\&quot;: \&quot;WxYzExampleNext\&quot;,                 \&quot;prev\&quot;: \&quot;WxYzExamplePrev\&quot;             }         }     }  The object contains two plans. The &#x60;total&#x60; attribute indicates that 19 plans are available in the List. To navigate forward in the **list**, use the &#x60;next&#x60; value (&#x60;WxYzExampleNext&#x60; in this example) as your &#x60;cursor&#x60; query parameter.      curl \&quot;https://api.vultr.com/v2/plans?per_page&#x3D;2&amp;cursor&#x3D;WxYzExampleNext\&quot; \       -X GET       -H \&quot;Authorization: Bearer ${VULTR_API_KEY}\&quot;  Likewise, you can use the example &#x60;prev&#x60; value &#x60;WxYzExamplePrev&#x60; to navigate backward.  ## Parameters  You can pass information to the API with three different types of parameters.  ### Path parameters  Some API calls require variable parameters as part of the endpoint path. For example, to retrieve information about a user, supply the &#x60;user-id&#x60; in the endpoint.      curl \&quot;https://api.vultr.com/v2/users/{user-id}\&quot; \       -X GET \       -H \&quot;Authorization: Bearer ${VULTR_API_KEY}\&quot;  ### Query parameters  Some API calls allow filtering with query parameters. For example, the &#x60;/v2/plans&#x60; endpoint supports a &#x60;type&#x60; query parameter. Setting &#x60;type&#x3D;vhf&#x60; instructs the API only to return High Frequency Compute plans in the list. You&#x27;ll find more specifics about valid filters in the endpoint documentation below.      curl \&quot;https://api.vultr.com/v2/plans?type&#x3D;vhf\&quot; \       -X GET \       -H \&quot;Authorization: Bearer ${VULTR_API_KEY}\&quot;  You can also combine filtering with paging. Use the &#x60;per_page&#x60; parameter to retreive a subset of vhf plans.      curl \&quot;https://api.vultr.com/v2/plans?type&#x3D;vhf&amp;per_page&#x3D;2\&quot; \       -X GET \       -H \&quot;Authorization: Bearer ${VULTR_API_KEY}\&quot;  ### Request Body  PUT, POST, and PATCH methods may include an object in the request body with a content type of **application/json**. The documentation for each endpoint below has more information about the expected object.  ## API Example Conventions  The examples in this documentation use &#x60;curl&#x60;, a command-line HTTP client, to demonstrate useage. Linux and macOS computers usually have curl installed by default, and it&#x27;s [available for download](https://curl.se/download.html) on all popular platforms including Windows.  Each example is split across multiple lines with the &#x60;\&#x60; character, which is compatible with a &#x60;bash&#x60; terminal. A typical example looks like this:      curl \&quot;https://api.vultr.com/v2/domains\&quot; \       -X POST \       -H \&quot;Authorization: Bearer ${VULTR_API_KEY}\&quot; \       -H \&quot;Content-Type: application/json\&quot; \       --data &#x27;{         \&quot;domain\&quot; : \&quot;example.com\&quot;,         \&quot;ip\&quot; : \&quot;192.0.2.123\&quot;       }&#x27;  * The &#x60;-X&#x60; parameter sets the request method. For consistency, we show the method on all examples, even though it&#x27;s not explicitly required for GET methods. * The &#x60;-H&#x60; lines set required HTTP headers. These examples are formatted to expand the VULTR\_API\_KEY environment variable for your convenience. * Examples that require a JSON object in the request body pass the required data via the &#x60;--data&#x60; parameter.  All values in this guide are examples. Do not rely on the OS or Plan IDs listed in this guide; use the appropriate endpoint to retreive values before creating resources.  # Authentication  &lt;!-- ReDoc-Inject: &lt;security-definitions&gt; --&gt;  # noqa: E501
    
