Skip to main content

Update information about a GitHub Enterprise Server Pages site

Updates information for a GitHub Enterprise Server Pages site. For more information, see "[About GitHub Pages](/github/working-with-github-pages/about-github-pages).

PUT/repos/{owner}/{repo}/pages
Source
github-v3-rest.json
Revision
f5f067c1e6f6
Active snapshot
85e53e3d0d65

Request

Path Parameters
owner string
required
repo string
required
Body Params
required
application/jsonobject
cname string
optionalnullable

Specify a custom domain for the repository. Sending a `null` value will remove the custom domain. For more about custom domains, see "[Using a custom domain with GitHub Pages](https://docs.github.com/articles/using-a-custom-domain-with-github-pages/)."

https_enforced boolean
optional

Specify whether HTTPS should be enforced for the repository.

public boolean
optional

Configures access controls for the GitHub Pages site. If public is set to `true`, the site is accessible to anyone on the internet. If set to `false`, the site will only be accessible to users who have at least `read` access to the repository that published the site. This includes anyone in your Enterprise if the repository is set to `internal` visibility. This feature is only available to repositories in an organization on an Enterprise plan.

source
optional

Responses

Response

application/json Basic Error object

Bad Request

documentation_url string
optional
message string
optional
status string
optional
url string
optional
application/scim+json Scim Error object

Bad Request

detail string
optionalnullable
documentation_url string
optionalnullable
message string
optionalnullable
schemas array[string]
optional
scimType string
optionalnullable
status integer
optional
application/json Validation Error object

Validation failed

documentation_url string
required
errors array[object]
optional
items object
code string
required
field string
optional
index integer
optional
message string
optional
resource string
optional
value
optional
message string
required