Projects API

The Projects API allows you to create, modify, delete and get detailed information about Bugsnag projects.

Projects represent individual applications on your Bugsnag account for which you are tracking errors.

List projects by account

Get a list of all Projects for the specified Bugsnag Account.

GET /accounts/:account_id/projects

Parameters

Name Description
sort What to sort results by. Can be only created_at. Default: created_at
direction The direction of the sort. Can be either asc or desc. Default: desc
per_page How many results to return per page. Default: 30

Response

Status: 200 OK
Link: <https://api.bugsnag.com/accounts/70baea119bf39c1431000004/projects?offset=50baee27a43ccdf778000002>; rel="next"

Body:

[
  {
    "id": "50baed119bf39c1431000004",
    "name": "Website",
    "api_key": "a0f5e56c125d2eeac31fd66e4f0cbd79",
    "errors": 78,
    "icon": "https://app.bugsnag.com/assets/frameworks/rails.png",
    "release_stages": ["production", "development"],
    "type": "rails",
    "created_at": "2012-12-02T05:54:25Z",
    "updated_at": "2013-06-17T19:57:49Z",
    "errors_url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004/errors",
    "events_url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004/events",
    "html_url": "https://app.bugsnag.com/dashboard/website",
    "url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004"
  }
]

List projects by user

Get a list of Projects to which the specified Bugsnag User has access.

GET /users/:user_id/projects

Parameters

Name Description
sort What to sort results by. Can be only created_at. Default: created_at
direction The direction of the sort. Can be either asc or desc. Default: desc
per_page How many results to return per page. Default: 30

Response

Status: 200 OK
Link: <https://api.bugsnag.com/users/515fb9337c1074f6fd000007/projects?offset=50baee27a43ccdf778000002>; rel="next"
[
  {
    "id": "50baed119bf39c1431000004",
    "name": "Website",
    "api_key": "a0f5e56c125d2eeac31fd66e4f0cbd79",
    "errors": 78,
    "icon": "https://app.bugsnag.com/assets/frameworks/rails.png",
    "release_stages": ["production", "development"],
    "type": "rails",
    "created_at": "2012-12-02T05:54:25Z",
    "updated_at": "2013-06-17T19:57:49Z",
    "errors_url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004/errors",
    "events_url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004/events",
    "html_url": "https://app.bugsnag.com/dashboard/website",
    "url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004"
  }
]

Get project details

Get the details of the specified Bugsnag Project.

GET /projects/:project_id

Response

Status: 200 OK

Body:

{
  "id": "50baed119bf39c1431000004",
  "name": "Website",
  "api_key": "a0f5e56c125d2eeac31fd66e4f0cbd79",
  "errors": 78,
  "icon": "https://app.bugsnag.com/assets/frameworks/rails.png",
  "release_stages": ["production", "development"],
  "type": "rails",
  "created_at": "2012-12-02T05:54:25Z",
  "updated_at": "2013-06-17T19:57:49Z",
  "errors_url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004/errors",
  "events_url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004/events",
  "html_url": "https://app.bugsnag.com/dashboard/website",
  "url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004"
}

Create a project

Create a new Project on the specified Bugsnag Account.

POST /accounts/:account_id/projects

Parameters

Name Description
name The project’s name, eg Website
type The type of the project, can be one of rails, django, php, android, ios, sinatra, node, unity, js, java or other. Default other

Response

Status: 201 Created

Body:

{
  "id": "50baed119bf39c1431000004",
  "name": "Website",
  "api_key": "a0f5e56c125d2eeac31fd66e4f0cbd79",
  "errors": 78,
  "icon": "https://app.bugsnag.com/assets/frameworks/rails.png",
  "release_stages": ["production", "development"],
  "type": "rails",
  "created_at": "2012-12-02T05:54:25Z",
  "updated_at": "2013-06-17T19:57:49Z",
  "errors_url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004/errors",
  "events_url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004/events",
  "html_url": "https://app.bugsnag.com/dashboard/website",
  "url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004"
}

Update a project

Update a Bugsnag Project’s name and other information. Responds with the newly updated Project.

PATCH /projects/:project_id

Parameters

Name Description
name The project’s name, eg Website
type The type of the project, can be one of rails, django, php, android, ios, sinatra, node, unity, js, java or other. Default other

Response

Status: 200 OK

Body:

{
  "id": "50baed119bf39c1431000004",
  "name": "Website",
  "api_key": "a0f5e56c125d2eeac31fd66e4f0cbd79",
  "errors": 78,
  "icon": "https://app.bugsnag.com/assets/frameworks/rails.png",
  "release_stages": ["production", "development"],
  "type": "rails",
  "created_at": "2012-12-02T05:54:25Z",
  "updated_at": "2013-06-17T19:57:49Z",
  "errors_url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004/errors",
  "events_url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004/events",
  "html_url": "https://app.bugsnag.com/dashboard/website",
  "url": "https://api.bugsnag.com/projects/50baed119bf39c1431000004"
}

Delete a project

Delete a Project and all associated Errors and Events from Bugsnag.

DELETE /projects/:project_id

Response

Status: 204 No Content