GitHub v3 REST API

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.

put
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/pages

Path Parameters

ownerstringrequired
repostringrequired

Body

application/json
Any Of

Response

Response

put/repos/{owner}/{repo}/pages

Body

{ "cname": "octocatblog.com", "source": { "branch": "main", "path": "/" } }
 

Delete a GitHub Enterprise Server Pages site

delete
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/pages

Path Parameters

ownerstringrequired
repostringrequired

Response

Response

delete/repos/{owner}/{repo}/pages
 

List GitHub Enterprise Server Pages builds

get
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/pages/builds

Query Parameters

per_pageinteger

Results per page (max 100)

Default:30

pageinteger

Page number of the results to fetch.

Default:1

Path Parameters

ownerstringrequired
repostringrequired

Response

200 application/json

Response

Page Build

urlstring(uri)required
statusstringrequired
errorobjectrequired
Show Child Parameters
pusherobject | nullrequired

Simple User

Show Child Parameters
commitstringrequired
durationintegerrequired
created_atstring(date-time)required
updated_atstring(date-time)required
get/repos/{owner}/{repo}/pages/builds
 
200 application/json

Request a GitHub Enterprise Server Pages build

You can request that your site be built from the latest revision on the default branch. This has the same effect as pushing a commit to your default branch, but does not require an additional commit. Manually triggering page builds can be helpful when diagnosing build warnings and failures.

Build requests are limited to one concurrent build per repository and one concurrent build per requester. If you request a build while another is still in progress, the second request will be queued until the first completes.

post
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/pages/builds

Path Parameters

ownerstringrequired
repostringrequired

Response

201 application/json

Response

Page Build Status

Page Build Status

urlstring(uri)required

Example:https://api.github.com/repos/github/hello-world/pages/builds/latest

statusstringrequired

Example:queued

post/repos/{owner}/{repo}/pages/builds
 
201 application/json

Get latest Pages build

get
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/pages/builds/latest

Path Parameters

ownerstringrequired
repostringrequired

Response

200 application/json

Response

Page Build

Page Build

urlstring(uri)required
statusstringrequired
errorobjectrequired
Show Child Parameters
pusherobject | nullrequired

Simple User

Show Child Parameters
commitstringrequired
durationintegerrequired
created_atstring(date-time)required
updated_atstring(date-time)required
get/repos/{owner}/{repo}/pages/builds/latest
 
200 application/json