github.com/danp/terraform@v0.9.5-0.20170426144147-39d740081351/website/source/docs/enterprise/api/index.html.md (about)

     1  ---
     2  layout: "enterprise"
     3  page_title: "API - Terraform Enterprise"
     4  sidebar_current: "docs-enterprise-api"
     5  description: |-
     6    Terraform Enterprise provides an API for a **subset of features**.
     7  ---
     8  
     9  # Terraform Enterprise API Documentation
    10  
    11  Terraform Enterprise provides an API for a **subset of features** available. For
    12  questions or requests for new API features please email
    13  [support@hashicorp.com](mailto:support@hashicorp.com).
    14  
    15  The list of available endpoints are on the navigation.
    16  
    17  ## Authentication
    18  
    19  All requests must be authenticated with an `X-Atlas-Token` HTTP header. This
    20  token can be generated or revoked on the account tokens page. Your token will
    21  have access to all resources your account has access to.
    22  
    23  For organization level resources, we recommend creating a separate user account
    24  that can be added to the organization with the specific privilege level
    25  required.
    26  
    27  ## Response Codes
    28  
    29  Standard HTTP response codes are returned. `404 Not Found` codes are returned
    30  for all resources that a user does not have access to, as well as for resources
    31  that don't exist. This is done to avoid a potential attacker discovering the
    32  existence of a resource.
    33  
    34  ## Errors
    35  
    36  Errors are returned in JSON format:
    37  
    38  ```json
    39  {
    40    "errors": {
    41      "name": [
    42        "has already been taken"
    43      ]
    44    }
    45  }
    46  ```
    47  
    48  ## Versioning
    49  
    50  The API currently resides under the `/v1` prefix. Future APIs will increment
    51  this version leaving the `/v1` API intact, though in the future certain features
    52  may be deprecated. In that case, ample notice to migrate to the new API will be
    53  provided.
    54  
    55  ## Content Type
    56  
    57  The API accepts namespaced attributes in either JSON or
    58  `application/x-www-form-urlencoded`. We recommend using JSON, but for simplicity
    59  form style requests are supported.