Delete an API key

Deletes an existing API key.

Access control

Endpoints

Deleting an API key is possible via these endpoints:

MethodPathAuthentication
DELETE
/apikeys/:id/jwtJSON Web Token
DELETE
/apikeys/:id/keyAPI Key & Secret

Request URL

The URL should contain the ID of the API key you wish to remove. It replaces the :id placeholder in the endpoints listed above.

Response status codes

Possible status codes for these endpoints are:

Status codeDescription
204
success
400
the request was malformed
401
the request lacks authentication
403
authentication failed
500
server error

Example request

Javascript
await axios.delete(
  'https://backend.freesewing.org/apikeys/7ea12968-7758-40b6-8c73-75cc99be762b/jwt',
  {
    headers: {
      Authorization: `Bearer ${token}`
    }
  }
)

Example response

JSON
204
NOTE

These endpoints return status code

204
(no content) on success, with no response body.