openapi: 3.0.1 info: title: Netlify Netlify's API documentation description: |- Netlify is a hosting service for the programmable web. It understands your documents and provides an API to handle atomic deploys of websites, manage form submissions, inject JavaScript snippets, and much more. This is a REST-style API that uses JSON for serialization and OAuth 2 for authentication. This document is an OpenAPI reference for the Netlify API that you can explore. For more detailed instructions for common uses, please visit the [online documentation](https://www.netlify.com/docs/api/). Visit our Community forum to join the conversation about [understanding and using Netlify’s API](https://community.netlify.com/t/common-issue-understanding-and-using-netlifys-api/160). Additionally, we have two API clients for your convenience: - [Go Client](https://github.com/netlify/open-api#go-client) - [JS Client](https://github.com/netlify/build/tree/main/packages/js-client) termsOfService: https://www.netlify.com/legal/terms-of-use/ version: 2.33.1 x-logo: url: netlify-logo.png href: https://www.netlify.com/docs/ altText: Netlify externalDocs: description: Online documentation url: https://www.netlify.com/docs/api/ servers: - url: https://api.netlify.com/api/v1 security: - netlifyAuth: [] tags: - name: accessToken x-displayName: Access token - name: accountMembership x-displayName: Accounts - name: accountType x-displayName: Access type - name: Asset x-displayName: Asset - name: assetPublicSignature x-displayName: Asset public signature - name: auditLog x-displayName: Audit log - name: Build x-displayName: Build - name: buildHook x-displayName: Build hook - name: buildLogMsg x-displayName: Build log message - name: Deploy x-displayName: Deploy - name: deployedBranch x-displayName: Deployed branch - name: deployKey x-displayName: Deploy key - name: devServer x-displayName: Dev server - name: devServerHook x-displayName: Dev server hook - name: dnsZone x-displayName: DNS zone - name: environmentVariables x-displayName: Environment variables - name: File x-displayName: File - name: Form x-displayName: Form - name: Function x-displayName: Function - name: Hook x-displayName: Hook - name: hookType x-displayName: Hook type - name: Member x-displayName: Member - name: Metadata x-displayName: Metadata - name: paymentMethod x-displayName: Payment method - name: Purge x-displayName: Cache purge - name: serviceInstance x-displayName: Service instance - name: Site x-displayName: Site - name: sniCertificate x-displayName: SNI certificate - name: Snippet x-displayName: Snippet - name: splitTest x-displayName: Split test - name: Submission x-displayName: Form submission - name: Ticket x-displayName: Ticket - name: User x-displayName: User - name: X-Internal paths: /sites: get: tags: - Site description: "**Note:** Environment variable keys and values have moved from `build_settings.env` and `repo.env` to a new endpoint. Please use [getEnvVars](#tag/environmentVariables/operation/getEnvVars) to retrieve site environment variables." operationId: listSites parameters: - name: name in: query schema: type: string - name: filter in: query schema: type: string enum: - all - owner - guest - name: page in: query schema: type: integer format: int32 - name: per_page in: query schema: type: integer format: int32 responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/site' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - Site description: "**Note:** Environment variable keys and values have moved from `build_settings.env` and `repo.env` to a new endpoint. Please use [createEnvVars](#tag/environmentVariables/operation/createEnvVars) to create environment variables for a site." operationId: createSite parameters: - name: configure_dns in: query schema: type: boolean requestBody: content: application/json: schema: $ref: '#/components/schemas/siteSetup' required: true responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/site' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: site /sites/{site_id}: get: tags: - Site description: "**Note:** Environment variable keys and values have moved from `build_settings.env` and `repo.env` to a new endpoint. Please use [getEnvVars](#tag/environmentVariables/operation/getEnvVars) to retrieve site environment variables." operationId: getSite parameters: - name: site_id in: path required: true schema: type: string - name: feature_flags in: query schema: type: string x-internal: true x-internal: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/site' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' delete: tags: - Site operationId: deleteSite parameters: - name: site_id in: path required: true schema: type: string responses: "204": description: Deleted content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' patch: tags: - Site description: "**Note:** Environment variable keys and values have moved from `build_settings.env` and `repo.env` to a new endpoint. Please use [updateEnvVar](#tag/environmentVariables/operation/updateEnvVar) to update a site's environment variables." operationId: updateSite parameters: - name: site_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/siteSetup' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/site' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: site /sites/{site_id}/ssl: get: tags: - sniCertificate operationId: showSiteTLSCertificate parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/sniCertificate' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - sniCertificate operationId: provisionSiteTLSCertificate parameters: - name: site_id in: path required: true schema: type: string - name: certificate in: query schema: type: string - name: key in: query schema: type: string - name: ca_certificates in: query schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/sniCertificate' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /accounts/{account_id}/env: get: tags: - environmentVariables description: "Returns all environment variables for an account or site. An account corresponds to a team in the Netlify UI. To use this endpoint, your site must no longer be using the classic environment variables experience. Migrate now with the Netlify UI." operationId: getEnvVars parameters: - name: account_id in: path description: Scope response to account_id required: true schema: type: string - name: context_name in: query description: Filter by deploy context schema: type: string enum: - all - dev - branch-deploy - deploy-preview - production - name: scope in: query description: Filter by scope schema: type: string enum: - builds - functions - runtime - post-processing - name: site_id in: query description: "If specified, only return environment variables set on this site" schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/envVar' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - environmentVariables description: "Creates new environment variables. Granular scopes are available on Pro plans and above. To use this endpoint, your site must no longer be using the classic environment variables experience. Migrate now with the Netlify UI." operationId: createEnvVars parameters: - name: account_id in: path description: Scope response to account_id required: true schema: type: string - name: site_id in: query description: "If provided, create an environment variable on the site level, not the account level" schema: type: string requestBody: content: application/json: schema: type: array items: type: object properties: key: type: string description: "The existing or new name of the key, if you wish to rename it (case-sensitive)" scopes: type: array description: The scopes that this environment variable is set to (Pro plans and above) items: type: string enum: - builds - functions - runtime - post-processing values: type: array items: $ref: '#/components/schemas/envVarValue' is_secret: type: boolean description: "Secret values are only readable by code running on Netlify’s systems. With secrets, only the local development context values are readable from the UI, API, and CLI. By default, environment variable values are not secret. (Enterprise plans only)" required: false responses: "201": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/envVar' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: env_vars /api/v1/sites/{site_id}/env: get: tags: - environmentVariables description: Returns all environment variables for a site. This convenience method behaves the same as `getEnvVars` but doesn't require an `account_id` as input. operationId: getSiteEnvVars parameters: - name: context_name in: query description: Filter by deploy context schema: type: string enum: - all - dev - branch-deploy - deploy-preview - production - name: scope in: query description: Filter by scope schema: type: string enum: - builds - functions - runtime - post_processing - name: site_id in: path description: Scope response to site_id required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/envVar' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /accounts/{account_id}/env/{key}: get: tags: - environmentVariables description: "Returns an individual environment variable. To use this endpoint, your site must no longer be using the classic environment variables experience. Migrate now with the Netlify UI." operationId: getEnvVar parameters: - name: account_id in: path description: Scope response to account_id required: true schema: type: string - name: key in: path description: The environment variable key (case-sensitive) required: true schema: type: string - name: site_id in: query description: "If provided, return the environment variable for a specific site (no merging is performed)" schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/envVar' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - environmentVariables description: "Updates an existing environment variable and all of its values. Existing values will be replaced by values provided. To use this endpoint, your site must no longer be using the classic environment variables experience. Migrate now with the Netlify UI." operationId: updateEnvVar parameters: - name: account_id in: path description: Scope response to account_id required: true schema: type: string - name: key in: path description: The existing environment variable key name (case-sensitive) required: true schema: type: string - name: site_id in: query description: "If provided, update an environment variable set on this site" schema: type: string requestBody: content: application/json: schema: type: object properties: key: type: string description: "The existing or new name of the key, if you wish to rename it (case-sensitive)" scopes: type: array description: The scopes that this environment variable is set to (Pro plans and above) items: type: string enum: - builds - functions - runtime - post-processing values: type: array items: $ref: '#/components/schemas/envVarValue' is_secret: type: boolean description: "Secret values are only readable by code running on Netlify’s systems. With secrets, only the local development context values are readable from the UI, API, and CLI. By default, environment variable values are not secret. (Enterprise plans only)" required: false responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/envVar' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: env_var delete: tags: - environmentVariables description: "Deletes an environment variable. To use this endpoint, your site must no longer be using the classic environment variables experience. Migrate now with the Netlify UI." operationId: deleteEnvVar parameters: - name: account_id in: path description: Scope response to account_id required: true schema: type: string - name: key in: path description: The environment variable key (case-sensitive) required: true schema: type: string - name: site_id in: query description: "If provided, delete the environment variable from this site" schema: type: string responses: "204": description: No Content (success) content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' patch: tags: - environmentVariables description: "Updates or creates a new value for an existing environment variable. To use this endpoint, your site must no longer be using the classic environment variables experience. Migrate now with the Netlify UI." operationId: setEnvVarValue parameters: - name: account_id in: path description: Scope response to account_id required: true schema: type: string - name: key in: path description: The existing environment variable key name (case-sensitive) required: true schema: type: string - name: site_id in: query description: "If provided, update an environment variable set on this site" schema: type: string requestBody: content: application/json: schema: type: object properties: context: type: string description: The deploy context in which this value will be used. `dev` refers to local development when running `netlify dev`. `branch` must be provided with a value in `context_parameter`. enum: - all - dev - branch-deploy - deploy-preview - production - branch context_parameter: type: string description: "An additional parameter for custom branches. Currently, this is used for providing a branch name when `context=branch`." value: type: string description: The environment variable's unencrypted value required: false responses: "201": description: Created (success) content: application/json: schema: $ref: '#/components/schemas/envVar' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: env_var /accounts/{account_id}/env/{key}/value/{id}: delete: tags: - environmentVariables description: "Deletes a specific environment variable value. To use this endpoint, your site must no longer be using the classic environment variables experience. Migrate now with the Netlify UI." operationId: deleteEnvVarValue parameters: - name: account_id in: path description: Scope response to account_id required: true schema: type: string - name: id in: path description: The environment variable value's ID required: true schema: type: string - name: key in: path description: The environment variable key name (case-sensitive) required: true schema: type: string - name: site_id in: query description: "If provided, delete the value from an environment variable on this site" schema: type: string responses: "204": description: No Content (success) content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/functions: get: tags: - Function operationId: searchSiteFunctions parameters: - name: site_id in: path required: true schema: type: string - name: filter in: query schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/siteFunction' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/forms: get: tags: - Form operationId: listSiteForms parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/form' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/forms/{form_id}: delete: tags: - Form operationId: deleteSiteForm parameters: - name: site_id in: path required: true schema: type: string - name: form_id in: path required: true schema: type: string responses: "204": description: Deleted content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/submissions: get: tags: - Submission operationId: listSiteSubmissions parameters: - name: site_id in: path required: true schema: type: string - name: page in: query schema: type: integer format: int32 - name: per_page in: query schema: type: integer format: int32 responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/submission' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/files: get: tags: - File operationId: listSiteFiles parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/file' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/assets: get: tags: - Asset operationId: listSiteAssets parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/asset' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - Asset operationId: createSiteAsset parameters: - name: site_id in: path required: true schema: type: string - name: name in: query required: true schema: type: string - name: size in: query required: true schema: type: integer format: int64 - name: content_type in: query required: true schema: type: string - name: visibility in: query schema: type: string responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/assetSignature' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/assets/{asset_id}: get: tags: - Asset operationId: getSiteAssetInfo parameters: - name: site_id in: path required: true schema: type: string - name: asset_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/asset' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - Asset operationId: updateSiteAsset parameters: - name: site_id in: path required: true schema: type: string - name: asset_id in: path required: true schema: type: string - name: state in: query required: true schema: type: string responses: "200": description: Updated content: application/json: schema: $ref: '#/components/schemas/asset' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' delete: tags: - Asset operationId: deleteSiteAsset parameters: - name: site_id in: path required: true schema: type: string - name: asset_id in: path required: true schema: type: string responses: "204": description: Deleted content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/assets/{asset_id}/public_signature: get: tags: - assetPublicSignature operationId: getSiteAssetPublicSignature parameters: - name: site_id in: path required: true schema: type: string - name: asset_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/assetPublicSignature' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/files/{file_path}: get: tags: - File operationId: getSiteFileByPathName parameters: - name: site_id in: path required: true schema: type: string - name: file_path in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/file' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /purge: post: tags: - Purge description: Purges cached content from Netlify's CDN. Supports purging by Cache-Tag. operationId: purgeCache requestBody: content: application/json: schema: $ref: '#/components/schemas/purge' required: true responses: "202": description: OK content: {} "400": description: Invalid request parameters content: {} "404": description: Site not found content: {} x-codegen-request-body-name: payload /sites/{site_id}/snippets: get: tags: - Snippet operationId: listSiteSnippets parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/snippet' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - Snippet operationId: createSiteSnippet parameters: - name: site_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/snippet' required: true responses: "201": description: OK content: application/json: schema: $ref: '#/components/schemas/snippet' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: snippet /sites/{site_id}/snippets/{snippet_id}: get: tags: - Snippet operationId: getSiteSnippet parameters: - name: site_id in: path required: true schema: type: string - name: snippet_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/snippet' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - Snippet operationId: updateSiteSnippet parameters: - name: site_id in: path required: true schema: type: string - name: snippet_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/snippet' required: true responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: snippet delete: tags: - Snippet operationId: deleteSiteSnippet parameters: - name: site_id in: path required: true schema: type: string - name: snippet_id in: path required: true schema: type: string responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/metadata: get: tags: - Metadata operationId: getSiteMetadata parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/metadata' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - Metadata operationId: updateSiteMetadata parameters: - name: site_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/metadata' required: true responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: metadata /sites/{site_id}/build_hooks: get: tags: - buildHook operationId: listSiteBuildHooks parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/buildHook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - buildHook operationId: createSiteBuildHook parameters: - name: site_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/buildHookSetup' required: true responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/buildHook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: buildHook /sites/{site_id}/build_hooks/{id}: get: tags: - buildHook operationId: getSiteBuildHook parameters: - name: site_id in: path required: true schema: type: string - name: id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/buildHook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - buildHook operationId: updateSiteBuildHook parameters: - name: site_id in: path required: true schema: type: string - name: id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/buildHookSetup' required: true responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: buildHook delete: tags: - buildHook operationId: deleteSiteBuildHook parameters: - name: site_id in: path required: true schema: type: string - name: id in: path required: true schema: type: string responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/deploys: get: tags: - Deploy operationId: listSiteDeploys parameters: - name: site_id in: path required: true schema: type: string - name: deploy-previews in: query schema: type: boolean - name: production in: query schema: type: boolean - name: state in: query schema: type: string enum: - new - pending_review - accepted - rejected - enqueued - building - uploading - uploaded - preparing - prepared - processing - processed - ready - error - retrying - name: branch in: query schema: type: string - name: latest-published in: query schema: type: boolean - name: page in: query schema: type: integer format: int32 - name: per_page in: query schema: type: integer format: int32 responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/deploy' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - Deploy operationId: createSiteDeploy parameters: - name: site_id in: path required: true schema: type: string - name: deploy-previews in: query schema: type: boolean - name: production in: query schema: type: boolean - name: state in: query schema: type: string enum: - new - pending_review - accepted - rejected - enqueued - building - uploading - uploaded - preparing - prepared - processing - processed - ready - error - retrying - name: branch in: query schema: type: string - name: latest-published in: query schema: type: boolean - name: title in: query schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/deployFiles' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/deploy' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: deploy /sites/{site_id}/deploys/{deploy_id}: get: tags: - Deploy operationId: getSiteDeploy parameters: - name: site_id in: path required: true schema: type: string - name: deploy_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/deploy' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - Deploy operationId: updateSiteDeploy parameters: - name: site_id in: path required: true schema: type: string - name: deploy_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/deployFiles' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/deploy' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: deploy delete: tags: - Deploy operationId: deleteSiteDeploy parameters: - name: deploy_id in: path required: true schema: type: string - name: site_id in: path required: true schema: type: string responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /deploys/{deploy_id}/cancel: post: tags: - Deploy operationId: cancelSiteDeploy parameters: - name: deploy_id in: path required: true schema: type: string responses: "201": description: Cancelled content: application/json: schema: $ref: '#/components/schemas/deploy' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/deploys/{deploy_id}/restore: post: tags: - Deploy operationId: restoreSiteDeploy parameters: - name: site_id in: path required: true schema: type: string - name: deploy_id in: path required: true schema: type: string responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/deploy' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/builds: get: tags: - Build operationId: listSiteBuilds parameters: - name: site_id in: path required: true schema: type: string - name: page in: query schema: type: integer format: int32 - name: per_page in: query schema: type: integer format: int32 responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/build' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - Build operationId: createSiteBuild parameters: - name: site_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/buildSetup' required: false responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/build' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: build /sites/{site_id}/deployed-branches: get: tags: - deployedBranch operationId: listSiteDeployedBranches parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/deployedBranch' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/unlink_repo: put: tags: - Site description: |- [Beta] Unlinks the repo from the site. This action will also: - Delete associated deploy keys - Delete outgoing webhooks for the repo - Delete the site's build hooks operationId: unlinkSiteRepo parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/site' "404": description: Site not found content: {} /builds/{build_id}: get: tags: - Build operationId: getSiteBuild parameters: - name: build_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/build' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /builds/{build_id}/log: post: tags: - buildLogMsg operationId: updateSiteBuildLog parameters: - name: build_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/buildLogMsg' required: true responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: msg /builds/{build_id}/start: post: tags: - Build operationId: notifyBuildStart parameters: - name: build_id in: path required: true schema: type: string - name: buildbot_version in: query schema: type: string - name: build_version in: query schema: type: string responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /{account_id}/builds/status: get: tags: - Build operationId: getAccountBuildStatus parameters: - name: account_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/buildStatus' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/dns: get: tags: - dnsZone operationId: getDNSForSite parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/dnsZone' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - dnsZone operationId: configureDNSForSite parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/dnsZone' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/rollback: put: tags: - Deploy operationId: rollbackSiteDeploy parameters: - name: site_id in: path required: true schema: type: string responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /deploys/{deploy_id}: get: tags: - Deploy operationId: getDeploy parameters: - name: deploy_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/deploy' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' delete: tags: - Deploy operationId: deleteDeploy parameters: - name: deploy_id in: path required: true schema: type: string responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /deploys/{deploy_id}/lock: post: tags: - Deploy operationId: lockDeploy parameters: - name: deploy_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/deploy' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /deploys/{deploy_id}/unlock: post: tags: - Deploy operationId: unlockDeploy parameters: - name: deploy_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/deploy' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /deploys/{deploy_id}/files/{path}: put: tags: - File operationId: uploadDeployFile parameters: - name: deploy_id in: path required: true schema: type: string - name: path in: path required: true schema: type: string - name: size in: query schema: type: integer requestBody: content: application/octet-stream: schema: type: string format: binary required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/file' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: file_body /deploys/{deploy_id}/functions/{name}: put: tags: - Function operationId: uploadDeployFunction parameters: - name: deploy_id in: path required: true schema: type: string - name: name in: path required: true schema: type: string - name: runtime in: query schema: type: string - name: invocation_mode in: query schema: type: string - name: timeout in: query schema: type: integer - name: size in: query schema: type: integer - name: X-Nf-Retry-Count in: header schema: type: integer requestBody: content: application/octet-stream: schema: type: string format: binary required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/function' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: file_body /sites/{site_id}/plugins/{package}: put: tags: - X-Internal description: This is an internal-only endpoint. operationId: updatePlugin parameters: - name: site_id in: path required: true schema: type: string - name: package in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/pluginParams' required: false responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/plugin' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-internal: true x-codegen-request-body-name: plugin_params /sites/{site_id}/plugin_runs/latest: get: tags: - X-Internal description: This is an internal-only endpoint. operationId: getLatestPluginRuns parameters: - name: site_id in: path required: true schema: type: string - name: packages in: query required: true style: form explode: false schema: type: array items: type: string - name: state in: query schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/pluginRun' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-internal: true /deploys/{deploy_id}/plugin_runs: post: tags: - X-Internal description: This is an internal-only endpoint. operationId: createPluginRun parameters: - name: deploy_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/pluginRunData' required: false responses: "201": description: CREATED content: application/json: schema: $ref: '#/components/schemas/pluginRun' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-internal: true x-codegen-request-body-name: plugin_run /forms/{form_id}/submissions: get: tags: - Submission operationId: listFormSubmissions parameters: - name: form_id in: path required: true schema: type: string - name: page in: query schema: type: integer format: int32 - name: per_page in: query schema: type: integer format: int32 responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/submission' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /hooks: get: tags: - Hook operationId: listHooksBySiteId parameters: - name: site_id in: query required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/hook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - Hook operationId: createHookBySiteId parameters: - name: site_id in: query required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/hook' required: true responses: "201": description: OK content: application/json: schema: $ref: '#/components/schemas/hook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: hook /hooks/{hook_id}: get: tags: - Hook operationId: getHook parameters: - name: hook_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/hook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - Hook operationId: updateHook parameters: - name: hook_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/hook' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/hook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: hook delete: tags: - Hook operationId: deleteHook parameters: - name: hook_id in: path required: true schema: type: string responses: "204": description: No content content: {} /hooks/{hook_id}/enable: post: tags: - Hook operationId: enableHook parameters: - name: hook_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/hook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /hooks/types: get: tags: - hookType operationId: listHookTypes responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/hookType' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /oauth/tickets: post: tags: - Ticket operationId: createTicket parameters: - name: client_id in: query required: true schema: type: string responses: "201": description: ok content: application/json: schema: $ref: '#/components/schemas/ticket' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /oauth/tickets/{ticket_id}: get: tags: - Ticket operationId: showTicket parameters: - name: ticket_id in: path required: true schema: type: string responses: "200": description: ok content: application/json: schema: $ref: '#/components/schemas/ticket' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /oauth/tickets/{ticket_id}/exchange: post: tags: - accessToken operationId: exchangeTicket parameters: - name: ticket_id in: path required: true schema: type: string responses: "201": description: ok content: application/json: schema: $ref: '#/components/schemas/accessToken' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /deploy_keys: get: tags: - deployKey operationId: listDeployKeys responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/deployKey' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - deployKey operationId: createDeployKey responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/deployKey' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /deploy_keys/{key_id}: get: tags: - deployKey operationId: getDeployKey parameters: - name: key_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/deployKey' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' delete: tags: - deployKey operationId: deleteDeployKey parameters: - name: key_id in: path required: true schema: type: string responses: "204": description: Not Content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /{account_slug}/sites: get: tags: - Site description: "**Note:** Environment variable keys and values have moved from `build_settings.env` and `repo.env` to a new endpoint. Please use [getEnvVars](#tag/environmentVariables/operation/getEnvVars) to retrieve site environment variables." operationId: listSitesForAccount parameters: - name: name in: query schema: type: string - name: account_slug in: path required: true schema: type: string - name: page in: query schema: type: integer format: int32 - name: per_page in: query schema: type: integer format: int32 responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/site' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - Site description: "**Note:** Environment variable keys and values have moved from `build_settings.env` and `repo.env` to a new endpoint. Please use [createEnvVars](#tag/environmentVariables/operation/createEnvVars) to create environment variables for a site." operationId: createSiteInTeam parameters: - name: configure_dns in: query schema: type: boolean - name: account_slug in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/siteSetup' required: false responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/site' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: site /{account_slug}/members: get: tags: - Member operationId: listMembersForAccount parameters: - name: account_slug in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/member' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - Member operationId: addMemberToAccount parameters: - name: account_slug in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/accountAddMemberSetup' required: true responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/member' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: accountAddMemberSetup /{account_slug}/members/{member_id}: get: tags: - Member operationId: getAccountMember parameters: - name: account_slug in: path required: true schema: type: string - name: member_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/member' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - Member operationId: updateAccountMember parameters: - name: account_slug in: path required: true schema: type: string - name: member_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/accountUpdateMemberSetup' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/member' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: accountUpdateMemberSetup delete: tags: - Member operationId: removeAccountMember parameters: - name: account_slug in: path required: true schema: type: string - name: member_id in: path required: true schema: type: string responses: "204": description: Not Content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /billing/payment_methods: get: tags: - paymentMethod operationId: listPaymentMethodsForUser responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/paymentMethod' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /accounts/types: get: tags: - accountType operationId: listAccountTypesForUser responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/accountType' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /accounts: get: tags: - accountMembership operationId: listAccountsForUser responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/accountMembership' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - accountMembership operationId: createAccount requestBody: content: application/json: schema: $ref: '#/components/schemas/accountSetup' required: true responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/accountMembership' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: accountSetup /accounts/{account_id}: get: tags: - accountMembership operationId: getAccount parameters: - name: account_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/accountMembership' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - accountMembership operationId: updateAccount parameters: - name: account_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/accountUpdateSetup' required: false responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/accountMembership' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: accountUpdateSetup delete: tags: - accountMembership operationId: cancelAccount parameters: - name: account_id in: path required: true schema: type: string responses: "204": description: Not Content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /accounts/{account_id}/audit: get: tags: - auditLog operationId: listAccountAuditEvents parameters: - name: account_id in: path required: true schema: type: string - name: query in: query schema: type: string - name: log_type in: query schema: type: string - name: page in: query schema: type: integer format: int32 - name: per_page in: query schema: type: integer format: int32 responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/auditLog' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /submissions/{submission_id}: get: tags: - Submission operationId: listFormSubmission parameters: - name: submission_id in: path required: true schema: type: string - name: query in: query schema: type: string - name: page in: query schema: type: integer format: int32 - name: per_page in: query schema: type: integer format: int32 responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/submission' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' delete: tags: - Submission operationId: deleteSubmission parameters: - name: submission_id in: path required: true schema: type: string responses: "204": description: Deleted content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/service-instances: get: tags: - serviceInstance operationId: listServiceInstancesForSite parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/serviceInstance' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/services/{addon}/instances: post: tags: - serviceInstance operationId: createServiceInstance parameters: - name: site_id in: path required: true schema: type: string - name: addon in: path required: true schema: type: string requestBody: content: application/json: schema: type: object required: true responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/serviceInstance' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: config /sites/{site_id}/services/{addon}/instances/{instance_id}: get: tags: - serviceInstance operationId: showServiceInstance parameters: - name: site_id in: path required: true schema: type: string - name: addon in: path required: true schema: type: string - name: instance_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/serviceInstance' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - serviceInstance operationId: updateServiceInstance parameters: - name: site_id in: path required: true schema: type: string - name: addon in: path required: true schema: type: string - name: instance_id in: path required: true schema: type: string requestBody: content: application/json: schema: type: object required: true responses: "204": description: No Content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: config delete: tags: - serviceInstance operationId: deleteServiceInstance parameters: - name: site_id in: path required: true schema: type: string - name: addon in: path required: true schema: type: string - name: instance_id in: path required: true schema: type: string responses: "204": description: Deleted content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /services/: get: tags: [] operationId: getServices parameters: - name: search in: query schema: type: string responses: "200": description: services content: application/json: schema: type: array items: $ref: '#/components/schemas/service' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /services/{addonName}: get: tags: [] operationId: showService parameters: - name: addonName in: path required: true schema: type: string responses: "200": description: services content: application/json: schema: $ref: '#/components/schemas/service' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /services/{addonName}/manifest: get: tags: [] operationId: showServiceManifest parameters: - name: addonName in: path required: true schema: type: string responses: "201": description: retrieving from provider content: application/json: schema: type: object default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /user: get: tags: - User operationId: getCurrentUser responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/user' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/traffic_splits: get: tags: - splitTest operationId: getSplitTests parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: split_tests content: application/json: schema: $ref: '#/components/schemas/splitTests' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - splitTest operationId: createSplitTest parameters: - name: site_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/splitTestSetup' required: true responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/splitTest' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: branch_tests /sites/{site_id}/traffic_splits/{split_test_id}: get: tags: - splitTest operationId: getSplitTest parameters: - name: site_id in: path required: true schema: type: string - name: split_test_id in: path required: true schema: type: string responses: "200": description: split_test content: application/json: schema: $ref: '#/components/schemas/splitTest' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - splitTest operationId: updateSplitTest parameters: - name: site_id in: path required: true schema: type: string - name: split_test_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/splitTestSetup' required: true responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/splitTest' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: branch_tests /sites/{site_id}/traffic_splits/{split_test_id}/publish: post: tags: - splitTest operationId: enableSplitTest parameters: - name: site_id in: path required: true schema: type: string - name: split_test_id in: path required: true schema: type: string responses: "204": description: enable content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/traffic_splits/{split_test_id}/unpublish: post: tags: - splitTest operationId: disableSplitTest parameters: - name: site_id in: path required: true schema: type: string - name: split_test_id in: path required: true schema: type: string responses: "204": description: disabled content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /dns_zones: get: tags: - dnsZone operationId: getDnsZones parameters: - name: account_slug in: query schema: type: string responses: "200": description: get all DNS zones the user has access to content: application/json: schema: $ref: '#/components/schemas/dnsZones' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - dnsZone operationId: createDnsZone requestBody: content: application/json: schema: $ref: '#/components/schemas/dnsZoneSetup' required: true responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/dnsZone' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: DnsZoneParams /dns_zones/{zone_id}: get: tags: - dnsZone operationId: getDnsZone parameters: - name: zone_id in: path required: true schema: type: string responses: "200": description: get a single DNS zone content: application/json: schema: $ref: '#/components/schemas/dnsZone' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' delete: tags: - dnsZone operationId: deleteDnsZone parameters: - name: zone_id in: path required: true schema: type: string responses: "204": description: delete a single DNS zone content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /dns_zones/{zone_id}/transfer: put: tags: - dnsZone operationId: transferDnsZone parameters: - name: zone_id in: path required: true schema: type: string - name: account_id in: query description: the account of the dns zone required: true schema: type: string - name: transfer_account_id in: query description: the account you want to transfer the dns zone to required: true schema: type: string - name: transfer_user_id in: query description: the user you want to transfer the dns zone to required: true schema: type: string responses: "200": description: transfer a DNS zone to another account content: application/json: schema: $ref: '#/components/schemas/dnsZone' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /dns_zones/{zone_id}/dns_records: get: tags: - dnsZone operationId: getDnsRecords parameters: - name: zone_id in: path required: true schema: type: string responses: "200": description: get all DNS records for a single DNS zone content: application/json: schema: $ref: '#/components/schemas/dnsRecords' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - dnsZone operationId: createDnsRecord parameters: - name: zone_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/dnsRecordCreate' required: true responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/dnsRecord' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: dns_record /dns_zones/{zone_id}/dns_records/{dns_record_id}: get: tags: - dnsZone operationId: getIndividualDnsRecord parameters: - name: zone_id in: path required: true schema: type: string - name: dns_record_id in: path required: true schema: type: string responses: "200": description: get a single DNS record content: application/json: schema: $ref: '#/components/schemas/dnsRecord' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' delete: tags: - dnsZone operationId: deleteDnsRecord parameters: - name: zone_id in: path required: true schema: type: string - name: dns_record_id in: path required: true schema: type: string responses: "204": description: record deleted content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/dev_servers: get: tags: - devServer operationId: listSiteDevServers parameters: - name: site_id in: path required: true schema: type: string - name: page in: query schema: type: integer format: int32 - name: per_page in: query schema: type: integer format: int32 responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/devServer' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - devServer operationId: createSiteDevServer parameters: - name: site_id in: path required: true schema: type: string - name: branch in: query schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/devServer' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' delete: tags: - devServer operationId: deleteSiteDevServers parameters: - name: site_id in: path required: true schema: type: string - name: branch in: query schema: type: string responses: "202": description: OK content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' /sites/{site_id}/dev_servers/{dev_server_id}: get: tags: - devServer operationId: getSiteDevServer parameters: - name: site_id in: path required: true schema: type: string - name: dev_server_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/devServer' /sites/{site_id}/dev_servers/{dev_server_id}/activity: post: tags: - devServer operationId: markDevServerActivity parameters: - name: site_id in: path required: true schema: type: string - name: dev_server_id in: path required: true schema: type: string responses: "200": description: OK content: {} x-internal: true /sites/{site_id}/dev_server_hooks: get: tags: - devServerHook operationId: listSiteDevServerHooks parameters: - name: site_id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: type: array items: $ref: '#/components/schemas/devServerHook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' post: tags: - devServerHook operationId: createSiteDevServerHook parameters: - name: site_id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/devServerHookSetup' required: true responses: "201": description: Created content: application/json: schema: $ref: '#/components/schemas/devServerHook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: devServerHook /sites/{site_id}/dev_server_hooks/{id}: get: tags: - devServerHook operationId: getSiteDevServerHook parameters: - name: site_id in: path required: true schema: type: string - name: id in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/devServerHook' default: description: error content: application/json: schema: $ref: '#/components/schemas/error' put: tags: - devServerHook operationId: updateSiteDevServerHook parameters: - name: site_id in: path required: true schema: type: string - name: id in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/devServerHookSetup' required: true responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' x-codegen-request-body-name: devServerHook delete: tags: - devServerHook operationId: deleteSiteDevServerHook parameters: - name: site_id in: path required: true schema: type: string - name: id in: path required: true schema: type: string responses: "204": description: No content content: {} default: description: error content: application/json: schema: $ref: '#/components/schemas/error' components: schemas: splitTestSetup: type: object properties: branch_tests: type: object properties: {} splitTests: type: array items: $ref: '#/components/schemas/splitTest' splitTest: type: object properties: id: type: string site_id: type: string name: type: string path: type: string branches: type: array items: type: object properties: {} active: type: boolean created_at: type: string format: dateTime updated_at: type: string format: dateTime unpublished_at: type: string format: dateTime serviceInstance: type: object properties: id: type: string url: type: string config: type: object properties: {} external_attributes: type: object properties: {} service_slug: type: string service_path: type: string service_name: type: string env: type: object properties: {} snippets: type: array items: type: object properties: {} auth_url: type: string created_at: type: string format: dateTime updated_at: type: string format: dateTime service: type: object properties: id: type: string name: type: string slug: type: string service_path: type: string long_description: type: string description: type: string events: type: array items: type: object properties: {} tags: type: array items: type: string icon: type: string manifest_url: type: string environments: type: array items: type: string created_at: type: string format: dateTime updated_at: type: string format: dateTime site: type: object properties: id: type: string state: type: string plan: type: string name: type: string custom_domain: type: string domain_aliases: type: array items: type: string branch_deploy_custom_domain: type: string deploy_preview_custom_domain: type: string password: type: string notification_email: type: string url: type: string ssl_url: type: string admin_url: type: string screenshot_url: type: string created_at: type: string format: dateTime updated_at: type: string format: dateTime user_id: type: string session_id: type: string ssl: type: boolean force_ssl: type: boolean managed_dns: type: boolean deploy_url: type: string published_deploy: $ref: '#/components/schemas/deploy' account_name: type: string account_slug: type: string git_provider: type: string deploy_hook: type: string capabilities: type: object additionalProperties: type: object properties: {} processing_settings: type: object properties: html: type: object properties: pretty_urls: type: boolean build_settings: $ref: '#/components/schemas/repoInfo' id_domain: type: string default_hooks_data: type: object properties: access_token: type: string build_image: type: string prerender: type: string functions_region: type: string siteSetup: allOf: - $ref: '#/components/schemas/site' - type: object properties: repo: $ref: '#/components/schemas/repoInfo' repoInfo: type: object properties: id: type: integer provider: type: string deploy_key_id: type: string repo_path: type: string repo_branch: type: string dir: type: string functions_dir: type: string cmd: type: string allowed_branches: type: array items: type: string public_repo: type: boolean private_logs: type: boolean repo_url: type: string env: type: object additionalProperties: type: string installation_id: type: integer stop_builds: type: boolean submission: type: object properties: id: type: string number: type: integer format: int32 email: type: string name: type: string first_name: type: string last_name: type: string company: type: string summary: type: string body: type: string data: type: object properties: {} created_at: type: string format: dateTime site_url: type: string envVar: type: object properties: key: type: string description: "The environment variable key, like ALGOLIA_ID (case-sensitive)" x-faker: commerce.productName scopes: type: array description: The scopes that this environment variable is set to items: type: string enum: - builds - functions - runtime - post-processing values: type: array description: An array of Value objects containing values and metadata items: $ref: '#/components/schemas/envVarValue' x-faker: internet.password is_secret: type: boolean description: "Secret values are only readable by code running on Netlify’s systems. With secrets, only the local development context values are readable from the UI, API, and CLI. By default, environment variable values are not secret. (Enterprise plans only)" updated_at: type: string description: The timestamp of when the value was last updated format: date-time x-faker: date.past updated_by: $ref: '#/components/schemas/envVarUser' description: Environment variable model definition envVarValue: type: object properties: id: type: string description: The environment variable value's universally unique ID x-faker: datatype.uuid value: type: string description: The environment variable's unencrypted value x-faker: internet.password context: type: string description: The deploy context in which this value will be used. `dev` refers to local development when running `netlify dev`. enum: - all - dev - branch-deploy - deploy-preview - production - branch context_parameter: type: string description: "An additional parameter for custom branches. Currently, this is used for specifying a branch name when `context=branch`." description: Environment variable value model definition envVarUser: type: object properties: id: type: string description: The user's unique identifier x-faker: datatype.number full_name: type: string description: The user's full name (first and last) x-faker: name.findName email: type: string description: The user's email address x-faker: internet.email avatar_url: type: string description: A URL pointing to the user's avatar x-faker: internet.avatar form: type: object properties: id: type: string site_id: type: string name: type: string paths: type: array items: type: string submission_count: type: integer format: int32 fields: type: array items: type: object properties: {} created_at: type: string format: dateTime hookType: type: object properties: name: type: string events: type: array items: type: string fields: type: array items: type: object properties: {} hook: type: object properties: id: type: string site_id: type: string type: type: string event: type: string data: type: object properties: {} created_at: type: string format: dateTime updated_at: type: string format: dateTime disabled: type: boolean file: type: object properties: id: type: string path: type: string sha: type: string mime_type: type: string size: type: integer format: int64 function: type: object properties: id: type: string name: type: string sha: type: string snippet: type: object properties: id: type: integer format: int32 site_id: type: string title: type: string general: type: string general_position: type: string goal: type: string goal_position: type: string purge: type: object properties: site_id: type: string site_slug: type: string cache_tags: type: array items: type: string deploy: type: object properties: id: type: string site_id: type: string user_id: type: string build_id: type: string state: type: string name: type: string url: type: string ssl_url: type: string admin_url: type: string deploy_url: type: string deploy_ssl_url: type: string screenshot_url: type: string review_id: type: number draft: type: boolean required: type: array items: type: string required_functions: type: array items: type: string error_message: type: string branch: type: string commit_ref: type: string commit_url: type: string skipped: type: boolean created_at: type: string format: dateTime updated_at: type: string format: dateTime published_at: type: string format: dateTime title: type: string context: type: string locked: type: boolean review_url: type: string framework: type: string function_schedules: type: array items: $ref: '#/components/schemas/functionSchedule' deployFiles: type: object properties: files: type: object properties: {} draft: type: boolean async: type: boolean functions: type: object properties: {} function_schedules: type: array items: $ref: '#/components/schemas/functionSchedule' functions_config: type: object additionalProperties: $ref: '#/components/schemas/functionConfig' branch: type: string framework: type: string framework_version: type: string pluginParams: type: object properties: pinned_version: type: string plugin: type: object properties: package: type: string pinned_version: type: string buildStatus: type: object properties: active: type: integer pending_concurrency: type: integer enqueued: type: integer build_count: type: integer minutes: type: object properties: current: type: integer current_average_sec: type: integer previous: type: integer period_start_date: type: string format: dateTime period_end_date: type: string format: dateTime last_updated_at: type: string format: dateTime included_minutes: type: string included_minutes_with_packs: type: string build: type: object properties: id: type: string deploy_id: type: string sha: type: string done: type: boolean error: type: string created_at: type: string format: dateTime buildLogMsg: type: object properties: message: type: string error: type: boolean section: type: string enum: - initializing - building - deploying - cleanup - postprocessing pluginRunData: type: object properties: package: type: string version: type: string state: type: string reporting_event: type: string title: type: string summary: type: string text: type: string pluginRun: allOf: - $ref: '#/components/schemas/pluginRunData' - type: object properties: deploy_id: type: string metadata: type: object dnsZoneSetup: type: object properties: account_slug: type: string site_id: type: string name: type: string dnsZones: type: array items: $ref: '#/components/schemas/dnsZone' dnsZone: type: object properties: id: type: string name: type: string errors: type: array items: type: string supported_record_types: type: array items: type: string user_id: type: string created_at: type: string format: dateTime updated_at: type: string format: dateTime records: type: array items: $ref: '#/components/schemas/dnsRecord' dns_servers: type: array items: type: string account_id: type: string site_id: type: string account_slug: type: string account_name: type: string domain: type: string ipv6_enabled: type: boolean dedicated: type: boolean dnsRecordCreate: type: object properties: type: type: string hostname: type: string value: type: string ttl: type: integer format: int64 priority: type: integer format: int64 weight: type: integer format: int64 port: type: integer format: int64 flag: type: integer format: int64 tag: type: string dnsRecords: type: array items: $ref: '#/components/schemas/dnsRecord' dnsRecord: type: object properties: id: type: string hostname: type: string type: type: string value: type: string ttl: type: integer format: int64 priority: type: integer format: int64 dns_zone_id: type: string site_id: type: string flag: type: integer tag: type: string managed: type: boolean sniCertificate: type: object properties: state: type: string domains: type: array items: type: string created_at: type: string format: dateTime updated_at: type: string format: dateTime expires_at: type: string format: dateTime ticket: type: object properties: id: type: string client_id: type: string authorized: type: boolean created_at: type: string format: dateTime accessToken: type: object properties: id: type: string access_token: type: string user_id: type: string user_email: type: string created_at: type: string format: dateTime asset: type: object properties: id: type: string site_id: type: string creator_id: type: string name: type: string state: type: string content_type: type: string url: type: string key: type: string visibility: type: string size: type: integer format: int64 created_at: type: string format: dateTime updated_at: type: string format: dateTime assetForm: type: object properties: url: type: string fields: type: object additionalProperties: type: string assetSignature: type: object properties: form: $ref: '#/components/schemas/assetForm' asset: $ref: '#/components/schemas/asset' assetPublicSignature: type: object properties: url: type: string deployKey: type: object properties: id: type: string public_key: type: string created_at: type: string format: dateTime member: type: object properties: id: type: string full_name: type: string email: type: string avatar: type: string role: type: string paymentMethod: type: object properties: id: type: string method_name: type: string type: type: string state: type: string data: type: object properties: card_type: type: string last4: type: string email: type: string created_at: type: string format: dateTime updated_at: type: string format: dateTime accountType: type: object properties: id: type: string name: type: string description: type: string capabilities: type: object properties: {} monthly_dollar_price: type: integer yearly_dollar_price: type: integer monthly_seats_addon_dollar_price: type: integer yearly_seats_addon_dollar_price: type: integer accountSetup: required: - name - type_id type: object properties: name: type: string type_id: type: string payment_method_id: type: string period: type: string enum: - monthly - yearly extra_seats_block: type: integer accountUpdateSetup: type: object properties: name: type: string slug: type: string type_id: type: string extra_seats_block: type: integer billing_name: type: string billing_email: type: string billing_details: type: string accountAddMemberSetup: type: object properties: role: type: string enum: - Owner - Developer - Billing Admin - Reviewer email: type: string accountUpdateMemberSetup: type: object properties: role: type: string enum: - Owner - Developer - Billing Admin - Reviewer site_access: type: string enum: - all - none - selected site_ids: type: array items: type: string accountMembership: type: object properties: id: type: string name: type: string slug: type: string type: type: string capabilities: type: object properties: sites: $ref: '#/components/schemas/accountUsageCapability' collaborators: $ref: '#/components/schemas/accountUsageCapability' billing_name: type: string billing_email: type: string billing_details: type: string billing_period: type: string payment_method_id: type: string type_name: type: string type_id: type: string owner_ids: type: array items: type: string roles_allowed: type: array items: type: string created_at: type: string format: dateTime updated_at: type: string format: dateTime auditLog: type: object properties: id: type: string account_id: type: string payload: type: object additionalProperties: type: object properties: {} accountUsageCapability: type: object properties: included: type: integer used: type: integer buildSetup: type: object properties: image: type: string clear_cache: type: boolean buildHookSetup: type: object properties: title: type: string branch: type: string buildHook: type: object properties: id: type: string title: type: string branch: type: string url: type: string site_id: type: string created_at: type: string format: dateTime deployedBranch: type: object properties: id: type: string deploy_id: type: string name: type: string slug: type: string url: type: string ssl_url: type: string user: type: object properties: id: type: string uid: type: string full_name: type: string avatar_url: type: string email: type: string affiliate_id: type: string site_count: type: integer format: int64 created_at: type: string format: dateTime last_login: type: string format: dateTime login_providers: type: array items: type: string onboarding_progress: type: object properties: slides: type: string error: required: - message type: object properties: code: type: integer format: int64 message: type: string nullable: false functionSchedule: type: object properties: name: type: string cron: type: string functionConfig: type: object properties: display_name: type: string generator: type: string build_data: type: object properties: {} routes: type: array items: $ref: '#/components/schemas/functionRoute' excluded_routes: type: array items: $ref: '#/components/schemas/excludedFunctionRoute' priority: type: integer traffic_rules: $ref: '#/components/schemas/trafficRulesConfig' functionRoute: type: object properties: pattern: type: string literal: type: string expression: type: string methods: type: array items: type: string enum: - GET - POST - PUT - PATCH - DELETE - OPTIONS prefer_static: type: boolean excludedFunctionRoute: type: object properties: pattern: type: string literal: type: string expression: type: string trafficRulesConfig: type: object properties: action: type: object properties: type: type: string config: type: object properties: to: type: string rate_limit_config: $ref: '#/components/schemas/trafficRulesRateLimitConfig' aggregate: $ref: '#/components/schemas/trafficRulesAggregateConfig' trafficRulesRateLimitConfig: type: object properties: algorithm: type: string enum: - sliding_window window_size: type: integer window_limit: type: integer trafficRulesAggregateConfig: type: object properties: keys: type: array items: type: object properties: type: type: string enum: - ip - domain siteFunction: type: object properties: branch: type: string created_at: type: string format: dateTime functions: type: array items: type: object properties: {} id: type: string log_type: type: string provider: type: string devServer: type: object properties: id: type: string site_id: type: string branch: type: string url: type: string state: type: string created_at: type: string format: dateTime updated_at: type: string format: dateTime starting_at: type: string format: dateTime error_at: type: string format: dateTime live_at: type: string format: dateTime done_at: type: string format: dateTime title: type: string devServerHook: type: object properties: id: type: string title: type: string branch: type: string url: type: string site_id: type: string created_at: type: string format: dateTime type: type: string enum: - new_dev_server - content_refresh devServerHookSetup: type: object properties: title: type: string branch: type: string type: type: string enum: - new_dev_server - content_refresh responses: error: description: error content: application/json: schema: $ref: '#/components/schemas/error' parameters: page: name: page in: query schema: type: integer format: int32 perPage: name: per_page in: query schema: type: integer format: int32 retryCount: name: X-Nf-Retry-Count in: header schema: type: integer securitySchemes: netlifyAuth: type: oauth2 flows: implicit: authorizationUrl: https://app.netlify.com/authorize scopes: {} x-tagGroups: - name: OAuth tags: - ticket - accessToken - name: User accounts tags: - user - accountMembership - member - accountType - paymentMethod - auditLog - name: Site tags: - site - environmentVariables - file - metadata - purge - snippet - name: Domain names tags: - dnsZone - sniCertificate - name: Deploys tags: - deploy - deployedBranch - deployKey - name: Builds tags: - build - buildLogMsg - name: Dev servers tags: - devServer - name: Webhooks and notifications tags: - hook - hookType - buildHook - devServerHook - name: Services tags: - service - serviceInstance - name: Functions tags: - function - name: Forms tags: - form - submission - name: Split tests tags: - splitTest - name: Large media tags: - asset - assetPublicSignature x-original-swagger-version: "2.0"