You are here:

Home

/

Documentation

/

Journals

Journals

Get the journals of the current user

This endpoint gets the journals of the current user.

This call is not paginated at the moment.

URL parameters

This endpoint does not have any parameters.

Query parameters

No query parameters are available for this endpoint.

Response attributes

type string

The type of the resource.

id string

The ID of the journal.

attributes object

The attributes of the journal.

attributes.name string

The name of the journal.

attributes.slug string

The slug of the journal.

attributes.avatar string

The avatar of the journal.

attributes.created_at integer

The date and time the object was created, in Unix timestamp format.

attributes.updated_at integer

The date and time the object was last updated, in Unix timestamp format.

links object

The links to access the journal.

GET /api/journals
{
"data": {
"type": "journal" ,
"id": "663" ,
"attributes": {
"name": "Dunder Mifflin" ,
"slug": "dunder-mifflin" ,
"avatar": "data:image/svg+xml;base64,..." ,
"created_at": 1751305720 ,
"updated_at": 1751305720
},
"links": {
"self": "https://j.codingcat12.net/api/organizations/663"
}
}
}

Get a specific journal

This endpoint gets a specific journal.

URL parameters

id integer required

The ID of the journal to get.

Query parameters

No query parameters are available for this endpoint.

Response attributes

type string

The type of the resource.

id string

The ID of the journal.

attributes object

The attributes of the journal.

attributes.name string

The name of the journal.

attributes.slug string

The slug of the journal.

attributes.avatar string

The avatar of the journal.

attributes.created_at integer

The date and time the object was created, in Unix timestamp format.

attributes.updated_at integer

The date and time the object was last updated, in Unix timestamp format.

links object

The links to access the journal.

GET /api/journals/{id}
{
"data": {
"type": "journal" ,
"id": "663" ,
"attributes": {
"name": "Dunder Mifflin" ,
"slug": "dunder-mifflin" ,
"avatar": "data:image/svg+xml;base64,..." ,
"created_at": 1751305720 ,
"updated_at": 1751305720
},
"links": {
"self": "https://j.codingcat12.net/api/organizations/663"
}
}
}

Create a journal

This endpoint creates a new journal. It will return the journal in the response. The avatar is automatically generated.

URL parameters

This endpoint does not have any parameters.

Query parameters

name string required

The name of the journal. Maximum 255 characters.

Response attributes

type string

The object type. Always 'journal'.

id integer

The ID of the journal.

attributes object

The attributes of the journal.

attributes.name string

The name of the journal.

attributes.slug string

The slug of the journal.

attributes.avatar string

The avatar of the journal.

attributes.created_at integer

The date and time the object was created, in Unix timestamp format.

attributes.updated_at integer

The date and time the object was last updated, in Unix timestamp format.

links object

The links of the journal.

self string

The URL of the journal.

POST /api/journals
{
"data": {
"type": "journal" ,
"id": "663" ,
"attributes": {
"name": "Dunder Mifflin" ,
"slug": "dunder-mifflin" ,
"avatar": "data:image/svg+xml;base64,..." ,
"created_at": 1751305720 ,
"updated_at": 1751305720
},
"links": {
"self": "https://j.codingcat12.net/api/organizations/663"
}
}
}

Update a journal

This endpoint updates the name of the journal. It will return the journal in the response. The avatar is automatically generated.

URL parameters

This endpoint does not have any parameters.

Query parameters

name string required

The name of the journal. Maximum 255 characters.

Response attributes

type string

The object type. Always 'journal'.

id integer

The ID of the journal.

attributes object

The attributes of the journal.

attributes.name string

The name of the journal.

attributes.slug string

The slug of the journal.

attributes.avatar string

The avatar of the journal.

attributes.created_at integer

The date and time the object was created, in Unix timestamp format.

attributes.updated_at integer

The date and time the object was last updated, in Unix timestamp format.

links object

The links of the journal.

self string

The URL of the journal.

PUT /api/journals/{id}
{
"data": {
"type": "journal" ,
"id": "663" ,
"attributes": {
"name": "Dunder Mifflin" ,
"slug": "dunder-mifflin" ,
"avatar": "data:image/svg+xml;base64,..." ,
"created_at": 1751305720 ,
"updated_at": 1751305720
},
"links": {
"self": "https://j.codingcat12.net/api/organizations/663"
}
}
}

Delete a journal

This endpoint deletes a journal. It will return a success message in the response.

URL parameters

id integer required

The ID of the journal.

Query parameters

No query parameters are available for this endpoint.

Response attributes

No response attributes are available for this endpoint.

DELETE /api/journals/{id}
No response body