The Notes API provides a simple interface to manage notes. The API allows you to create, delete and update your notes. You can retrieve a single note as well as list of all notes.

You can assign as many notes as you want to any of the resources listed below:

JSON format

NameRead OnlyTypeDescription
idtruenumberUnique identifier of the note.
creator_idtruenumberUnique identifier of the user that created the note.
resource_typefalsestringType name of the resource the note is attached to. Possible values: lead, contact, deal
resource_idfalsenumberUnique identifier of the resource the note is attached to.
contentfalsestringContent of the note.
is_importantfalsebooleanIndicator for whether the note has been starred or not.
tagsfalsearrayAn array of tags for a note. See more at Tags.
created_attruestringDate and time of creation in UTC (ISO8601 format).
updated_attruestringDate and time of the last update in UTC (ISO8601 format).
typefalsestringType of the note which governs the permissions to the note. Use restricted to narrow the access only to the note creator (as denoted by creator_id field) and regular in all other cases. Possible values: regular, restricted

Retrieve all notes

GET /v2/notes

Returns all notes available to the user, according to the parameters provided.

Parameters

NameRequiredTypeInDescription
pagefalsenumberQueryPage number to start from. Page numbering starts at 1, and omitting the page parameter will return the first page.
per_pagefalsenumberQueryNumber of records to return per page. The default limit is 25 and the maximum number that can be returned at one time is 100.
sort_byfalsestringQueryA field to sort by. Default ordering is ascending. If you want to change the sort ordering to descending, append :desc to the field e.g. sort_by=resource_type:desc. Possible values, resource_type, created_at, updated_at
includesfalsestringQueryComma-separated list of one or more resources related to the note. Not supported at the moment.
idsfalsestringQueryComma-separated list of note IDs to be returned in a request.
creator_idfalsenumberQueryUnique identifier of the user. Returns all notes created by the user.
qfalsestringQueryA query string to search for. Performs a full text search on the content field.
resource_typefalsestringQueryName of the type of resource to search for. Possible values: lead, contact, deal
resource_idfalsenumberQueryUnique identifier of the resource to search for.

Allowed for

  • Agents

Using cURL

curl -v -X GET https://api.getbase.com/v2/notes?resource_type=deals \-H "Accept: application/json" \-H "Authorization: Bearer $ACCESS_TOKEN"

Example response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8Content-Language: en
{  "items": [    {      "data": {        "id": 1,        "creator_id": 1,        "resource_type": "lead",        "resource_id": 1,        "content": "Highly important.",        "is_important": true,        "tags": [          "premium"        ],        "created_at": "2014-08-27T16:32:56Z",        "updated_at": "2014-08-27T17:32:56Z",        "type": "regular"      },      "meta": {        "type": "note"      }    }  ],  "meta": {    "type": "collection",    "count": 1,    "links": {      "self": "http://api.getbase.com/v2/notes.json"    }  }}

Create a note

POST /v2/notes

Create a new note and associate it with one of the resources listed below:

Parameters

NameRequiredTypeInDescription
resource_typetruestringBodye.g. lead
resource_idtruenumberBody
contenttruestringBodye.g.Highly important.
is_importantfalsebooleanBody
tagsfalsearrayBodye.g. "tags":["premium"]
typefalsestringBodye.g. "type":regular

Allowed for

  • Agents

Using cURL

curl -v -X POST https://api.getbase.com/v2/notes \-H "Accept: application/json" \-H "Content-Type: application/json" \-H "Authorization: Bearer $ACCESS_TOKEN" \-d '{  "data": {    "resource_type": "lead",    "resource_id": 1,    "content": "Highly important.",    "is_important": true,    "tags": [      "premium"    ],    "type": "regular"  },  "meta": {    "type": "note"  }}'

Example response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8Content-Language: en
{  "data": {    "id": 1,    "creator_id": 1,    "resource_type": "lead",    "resource_id": 1,    "content": "Highly important.",    "is_important": true,    "tags": [      "premium"    ],    "created_at": "2014-08-27T16:32:56Z",    "updated_at": "2014-08-27T17:32:56Z",    "type": "regular"  },  "meta": {    "type": "note"  }}

Retrieve a single note

GET /v2/notes/:id

Returns a single note available to the user, according to the unique note ID provided. If the note ID does not exist, this request will return an error.

Parameters

NameRequiredTypeInDescription
idtruenumberQueryUnique identifier of the note.

Allowed for

  • Agents

Using cURL

curl -v -X GET https://api.getbase.com/v2/notes/1 \-H "Accept: application/json" \-H "Authorization: Bearer $ACCESS_TOKEN"

Example response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8Content-Language: en
{  "data": {    "id": 1,    "creator_id": 1,    "resource_type": "lead",    "resource_id": 1,    "content": "Highly important.",    "is_important": true,    "tags": [      "premium"    ],    "created_at": "2014-08-27T16:32:56Z",    "updated_at": "2014-08-27T17:32:56Z",    "type": "regular"  },  "meta": {    "type": "note"  }}

Update a note

PUT /v2/notes/:id

Updates note information. If the note ID does not exist, this request will return an error.

Parameters

NameRequiredTypeInDescription
resource_typefalsestringBodye.g.lead
resource_idfalsenumberQuerye.g.1
contentfalsestringBodye.g. Highly important. Assign to Tom.)
is_importantfalsebooleanBody
tagsfalsearrayBodye.g. ["premium"]
typefalsestringBodye.g. regular

Allowed for

  • Agents

Using cURL

curl -v -X PUT https://api.getbase.com/v2/notes/1 \-H "Accept: application/json" \-H "Content-Type: application/json" \-H "Authorization: Bearer $ACCESS_TOKEN" \-d '{  "data": {    "content": "Highly important. Assign to Tom."  }}'

Example response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8Content-Language: en
{  "data": {    "id": 1,    "creator_id": 1,    "resource_type": "lead",    "resource_id": 1,    "content": "Highly important. Assign to Tom.",    "is_important": true,    "tags": [      "premium"    ],    "created_at": "2014-08-27T16:32:56Z",    "updated_at": "2014-08-27T17:32:56Z",    "type": "regular"  },  "meta": {    "type": "note"  }}

Delete a note

DELETE /v2/notes/:id

Delete an existing note. If the note ID does not exist, this request will return an error. This operation cannot be undone.

Parameters

NameRequiredTypeInDescription
idtruenumberBodyUnique identifier of the note.

Allowed for

  • Agents

Using cURL

curl -v -X DELETE https://api.getbase.com/v2/notes/1 \-H "Authorization: Bearer $ACCESS_TOKEN"

Example response

HTTP/1.1 204 No Content