Sample - GitHub REST API
DELETE/orgs/{org}/campaigns/{campaign_number}

Delete a campaign for an organization

Deletes a campaign in an organization.

The authenticated user must be an owner or security manager for the organization to use this endpoint.

OAuth app tokens and personal access tokens (classic) need the security_events scope to use this endpoint.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

2 parameters
orgstringrequired
The organization name. The name is not case sensitive.
campaign_numberintegerrequired
The campaign number.

3 status codes
204Deletion successful
404Resource not found
messagestringoptional
documentation_urlstringoptional
urlstringoptional
statusstringoptional
503Service unavailable
codestringoptional
messagestringoptional
documentation_urlstringoptional

Error handling

A 404 is returned: Resource not found. A 503 is returned: Service unavailable.