Notes


All Notes

You can get a list of all the notes of a campaign by using the following endpoint.

{warning} Don't forget that all endpoints documented here need to be prefixed with api/1.0/campaigns/{campaign.id}/.

Method Endpoint Headers
GET/HEAD notes Default

Results

{
    "data": [
        {
            "id": 1,
            "name": "Legends of the World",
            "entry": "\n<p>Lorem Ipsum.</p>\n",
            "image": "{path}",
            "image_full": "{url}",
            "image_thumb": "{url}",
            "has_custom_image": false,
            "is_private": true,
            "entity_id": 7,
            "note_id": null,
            "tags": [],
            "created_at":  "2019-01-30T00:01:44.000000Z",
            "created_by": 1,
            "updated_at":  "2019-08-29T13:48:54.000000Z",
            "updated_by": 1,
            "type": "Lore",
            "is_pinned": 0
        }
    ]
}

Note

To get the details of a single note, use the following endpoint.

Method Endpoint Headers
GET/HEAD notes/{note.id} Default

Results

{
    "data": {
        "id": 1,
        "name": "Legends of the World",
        "entry": "\n<p>Lorem Ipsum.</p>\n",
        "image": "{path}",
        "image_full": "{url}",
        "image_thumb": "{url}",
        "has_custom_image": false,
        "is_private": true,
        "entity_id": 7,
        "note_id": null,
        "tags": [],
        "created_at":  "2019-01-30T00:01:44.000000Z",
        "created_by": 1,
        "updated_at":  "2019-08-29T13:48:54.000000Z",
        "updated_by": 1,
        "type": "Lore",
        "is_pinned": 0
    }

}

Create a Note

To create a note, use the following endpoint.

Method Endpoint Headers
POST notes Default

Body

Parameter Type Detail
name string (Required) Name of the note
type string The note's type
note_id integer The parent note id
tags array Array of tag ids
is_private boolean If the note is only visible to admin members of the campaign
image stream Stream to file uploaded to the note
image_url string URL to a picture to be used for the note

Results

{success} Code 200 with JSON body of the new note.

Update a Note

To update a note, use the following endpoint.

Method Endpoint Headers
PUT/PATCH notes/{note.id} Default

Body

The same body parameters are available as for when creating a note.

Results

{success} Code 200 with JSON body of the updated note.

Delete a Note

To delete a note, use the following endpoint.

Method Endpoint Headers
DELETE notes/{note.id} Default

Results

{success} Code 200 with JSON.