Introduction

Rapid Logging for Productivity and Journaling via Laravel Framework with an Instrument-Agnostic Approach

This documentation aims to provide all the information you need to work with the JotSauce API.

Authenticating requests

To authenticate requests, include an Authorization header with the value "Bearer {YOUR_AUTH_KEY}".

All authenticated endpoints are marked with a requires authentication badge in the documentation below.

You can retrieve your token by using the Login endpoint.

Authentication

Email Availability

POST
https://jotsauce.com
/api/auth/email-availability

Check if an email has already been used to register.

Headers

Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Example request:
curl --request POST \
    "https://jotsauce.com/api/auth/email-availability" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"example@jotsauce.com\"
}"
Example response:
{
    "available": true
}
{
    "message": "The email has already been taken.",
    "errors": {
        "email": [
            "The email has already been taken."
        ]
    }
}

Username Availability

POST
https://jotsauce.com
/api/auth/username-availability

Check if a username has already been used to register.

Headers

Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Example request:
curl --request POST \
    "https://jotsauce.com/api/auth/username-availability" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"username\": \"baeutldntxyibwzapkxx\"
}"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    x-ratelimit-limit
                                                            : 60
                                                                                                                    x-ratelimit-remaining
                                                            : 56
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "available": true
}

Register

POST
https://jotsauce.com
/api/auth/register

Before submitting a Register request, you may use the Email Availability and Username Availability endpoints to determine if they are already in use.

Headers

Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Example request:
curl --request POST \
    "https://jotsauce.com/api/auth/register" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"username\": \"n\",
    \"email\": \"fcorkery@example.com\",
    \"password\": \";0A|gXl2\",
    \"token\": \"b7692ddf-4969-357a-ad74-44e85086d5bc\"
}"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    x-ratelimit-limit
                                                            : 60
                                                                                                                    x-ratelimit-remaining
                                                            : 57
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "message": "The username field must be at least 3 characters. (and 2 more errors)",
    "errors": {
        "username": [
            "The username field must be at least 3 characters."
        ],
        "password": [
            "The password field confirmation does not match."
        ],
        "token": [
            "The selected token is invalid."
        ]
    }
}

Login

POST
https://jotsauce.com
/api/auth/login

Headers

Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Example request:
curl --request POST \
    "https://jotsauce.com/api/auth/login" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email_or_username\": \"example@jotsauce.com\",
    \"password\": \"Password123!\"
}"
Example response:

Logout

GET
https://jotsauce.com
/api/auth/logout
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/auth/logout" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Settings

Settings

GET
https://jotsauce.com
/api/settings

Return General Settings For The API

Headers

Content-Type
Example:
application/json
Accept
Example:
application/json
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/settings" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    x-ratelimit-limit
                                                            : 60
                                                                                                                    x-ratelimit-remaining
                                                            : 54
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "invitations": {
        "invite_only": true,
        "default_invitations_remaining": 3
    }
}

Invitation Requests

Store

POST
https://jotsauce.com
/api/invitationRequests

Create a new Invitation Request

Headers

Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Example request:
curl --request POST \
    "https://jotsauce.com/api/invitationRequests" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"example@jotsauce.com\",
    \"message\": \"Please let me join!\"
}"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    x-ratelimit-limit
                                                            : 60
                                                                                                                    x-ratelimit-remaining
                                                            : 55
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "email": "example@jotsauce.com",
    "message": "Please let me join!",
    "created_at": "2023-11-08T23:19:22.000000Z"
}

Invitations

Verify Invitation Token

POST
https://jotsauce.com
/api/auth/invitation-token-verification

Check To See If Invitation Token Is Valid

Headers

Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Example request:
curl --request POST \
    "https://jotsauce.com/api/auth/invitation-token-verification" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"token\": \"4178aa4d-96c4-3c52-9b43-d4e94c27169c\"
}"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    x-ratelimit-limit
                                                            : 60
                                                                                                                    x-ratelimit-remaining
                                                            : 59
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "message": "The selected token is invalid.",
    "errors": {
        "token": [
            "The selected token is invalid."
        ]
    }
}

Index

GET
https://jotsauce.com
/api/invitations
requires authentication

List Of Invitations

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/invitations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Store

POST
https://jotsauce.com
/api/invitations
requires authentication

Create A New Invitation

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Example request:
curl --request POST \
    "https://jotsauce.com/api/invitations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"example@jotsauce.com\"
}"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Show

GET
https://jotsauce.com
/api/invitations/{id}
requires authentication

Return The Specified Invitation

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the invitation.

Example:
magni
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/invitations/magni" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Destroy

DELETE
https://jotsauce.com
/api/invitations/{id}
requires authentication

Delete The Specified Invitation

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the invitation.

Example:
qui
Example request:
curl --request DELETE \
    "https://jotsauce.com/api/invitations/qui" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Restore

PUT
PATCH
https://jotsauce.com
/api/invitations/{invitation_id}/restore
requires authentication

Restore The Specified Trashed (Soft-Deleted) Invitation

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

invitation_id
string
required

The ID of the invitation.

Example:
sint
Example request:
curl --request PUT \
    "https://jotsauce.com/api/invitations/sint/restore" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Trashed Index

GET
https://jotsauce.com
/api/invitations/trashed
requires authentication

List Of Trashed (Soft-Deleted) Invitations

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/invitations/trashed" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Trashed

GET
https://jotsauce.com
/api/invitations/{invitation_id}/trashed
requires authentication

Return The Specified Trashed (Soft-Deleted) Invitation

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

invitation_id
string
required

The ID of the invitation.

Example:
tempora
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/invitations/tempora/trashed" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Annihilate

DELETE
https://jotsauce.com
/api/invitations/{invitation_id}/annihilate
requires authentication

Permanently Remove The Invitation From The Server

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

invitation_id
string
required

The ID of the invitation.

Example:
facere
Example request:
curl --request DELETE \
    "https://jotsauce.com/api/invitations/facere/annihilate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Jots

Handle the incoming request.

GET
https://jotsauce.com
/api/jots/archived
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/jots/archived" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Trashed (soft deleted) Jot index

GET
https://jotsauce.com
/api/jots/trashed
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/jots/trashed" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Annihilate the specified Jot

DELETE
https://jotsauce.com
/api/jots/{jot_id}/annihilate
requires authentication

Permanently remove Jot from the server

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

jot_id
string
required

The ID of the jot.

Example:
11903b26-8e9d-440e-869b-aab0a2bc97b9
Example request:
curl --request DELETE \
    "https://jotsauce.com/api/jots/11903b26-8e9d-440e-869b-aab0a2bc97b9/annihilate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Handle the incoming request.

PUT
PATCH
https://jotsauce.com
/api/jots/{jot_id}/archive
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

jot_id
string
required

The ID of the jot.

Example:
11903b26-8e9d-440e-869b-aab0a2bc97b9
Example request:
curl --request PUT \
    "https://jotsauce.com/api/jots/11903b26-8e9d-440e-869b-aab0a2bc97b9/archive" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Handle the incoming request.

GET
https://jotsauce.com
/api/jots/{jot_id}/archived
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

jot_id
string
required

The ID of the jot.

Example:
11903b26-8e9d-440e-869b-aab0a2bc97b9
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/jots/11903b26-8e9d-440e-869b-aab0a2bc97b9/archived" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Restore the specified trashed (soft deleted) Jot

PUT
PATCH
https://jotsauce.com
/api/jots/{jot_id}/restore
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

jot_id
string
required

The ID of the jot.

Example:
11903b26-8e9d-440e-869b-aab0a2bc97b9
Example request:
curl --request PUT \
    "https://jotsauce.com/api/jots/11903b26-8e9d-440e-869b-aab0a2bc97b9/restore" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Return the trashed (soft deleted) Jot

GET
https://jotsauce.com
/api/jots/{jot_id}/trashed
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

jot_id
string
required

The ID of the jot.

Example:
11903b26-8e9d-440e-869b-aab0a2bc97b9
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/jots/11903b26-8e9d-440e-869b-aab0a2bc97b9/trashed" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Handle the incoming request.

PUT
PATCH
https://jotsauce.com
/api/jots/{jot_id}/unarchive
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

jot_id
string
required

The ID of the jot.

Example:
11903b26-8e9d-440e-869b-aab0a2bc97b9
Example request:
curl --request PUT \
    "https://jotsauce.com/api/jots/11903b26-8e9d-440e-869b-aab0a2bc97b9/unarchive" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Jot index

GET
https://jotsauce.com
/api/jots
requires authentication

Return a list of jots created by the user.

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/jots" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Create a new Jot

POST
https://jotsauce.com
/api/jots
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

Body Parameters

Example request:
curl --request POST \
    "https://jotsauce.com/api/jots" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"Weight Tracker\",
    \"description\": \"A Daily Weight Tracker\",
    \"slug\": \"research-paper\",
    \"order\": 3,
    \"is_public\": false
}"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Return specified Jot

GET
https://jotsauce.com
/api/jots/{id}
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the jot.

Example:
11903b26-8e9d-440e-869b-aab0a2bc97b9
Example request:
curl --request GET \
    --get "https://jotsauce.com/api/jots/11903b26-8e9d-440e-869b-aab0a2bc97b9" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
Example response:
Headers
                                                            cache-control
                                                            : no-cache, private
                                                                                                                    content-type
                                                            : application/json
                                                                                                                    vary
                                                            : Origin
                                                         
{
    "success": false,
    "message": "Unauthenticated.",
    "data": []
}

Update the specified Jot

PUT
PATCH
https://jotsauce.com
/api/jots/{id}
requires authentication

Headers

Authorization
Example:
Bearer {YOUR_AUTH_KEY}
Content-Type
Example:
application/json
Accept
Example:
application/json

URL Parameters

id
string
required

The ID of the jot.

Example:
11903b26-8e9d-440e-869b-aab0a2bc97b9

Body Parameters