OpenAPI Specification
openapi: 3.0.1
info:
title: Elementum Access Token Comments API
description: Manage access tokens using OAuth 2.0 standards
contact:
email: apiteam@elementum.io
version: 0.0.1
servers:
- url: /v1
tags:
- name: Comments
description: Manage the conversation of a record
paths:
/{recordType}/{alias}/{id}/comment:
get:
tags:
- Comments
summary: Get the list of comments
operationId: listRecordComments
parameters:
- $ref: '#/components/parameters/recordType'
- $ref: '#/components/parameters/alias'
- $ref: '#/components/parameters/recordId'
- $ref: '#/components/parameters/first'
- $ref: '#/components/parameters/after'
- $ref: '#/components/parameters/last'
- $ref: '#/components/parameters/before'
responses:
'200':
description: Ok
content:
application/json:
schema:
$ref: '#/components/schemas/CommentPagedList'
'400':
$ref: '#/components/responses/400'
'401':
$ref: '#/components/responses/401'
'403':
$ref: '#/components/responses/403'
'404':
$ref: '#/components/responses/404'
'422':
$ref: '#/components/responses/422'
'429':
$ref: '#/components/responses/429'
'500':
$ref: '#/components/responses/500'
security:
- ClientCredentials: []
x-codegen-request-body-name: body
post:
tags:
- Comments
summary: Add a comment
operationId: createRecordComment
parameters:
- $ref: '#/components/parameters/recordType'
- $ref: '#/components/parameters/alias'
- $ref: '#/components/parameters/recordId'
requestBody:
description: The comment to be added
content:
text/plain:
schema:
type: string
required: true
responses:
'201':
description: Created
content:
text/plain:
schema:
type: string
'400':
$ref: '#/components/responses/400'
'401':
$ref: '#/components/responses/401'
'403':
$ref: '#/components/responses/403'
'404':
$ref: '#/components/responses/404'
'422':
$ref: '#/components/responses/422'
'429':
$ref: '#/components/responses/429'
'500':
$ref: '#/components/responses/500'
security:
- ClientCredentials: []
x-codegen-request-body-name: body
components:
parameters:
last:
name: last
in: query
description: The number of elements to retrieve before the 'before' cursor location
required: false
schema:
maximum: 1000
minimum: 1
type: integer
format: int32
after:
name: after
in: query
description: The starting cursor to begin searching, defaults to the beginning of the list
required: false
schema:
type: string
recordType:
name: recordType
in: path
description: '''apps'', ''elements'', ''tasks'', or ''transactions'''
required: true
schema:
type: string
format: string
recordId:
name: id
in: path
description: The record ID
required: true
schema:
type: string
format: string
alias:
name: alias
in: path
description: The app's namespace or its UUID
required: true
schema:
type: string
format: string
before:
name: before
in: query
description: The starting cursor to begin searching, defaults to the end of the list
required: false
schema:
type: string
first:
name: first
in: query
description: The number of elements to retrieve after the 'after' cursor location
required: false
schema:
maximum: 1000
minimum: 1
type: integer
format: int32
default: 100
schemas:
Comment:
type: object
properties:
id:
type: string
description: The comment ID
format: uuid
createdAt:
type: string
description: When the comment was created
format: date-time
source:
type: string
description: The source of the comment (WEB, API, WORKFLOW, etc.)
contents:
type: string
description: The comment text
createdBy:
$ref: '#/components/schemas/User'
example: '{id=550e8400-e29b-41d4-a716-446655440000, createdAt=2026-04-04T03:25:38.045Z, source=API, contents=Shipment delayed due to weather, createdBy={firstName=Jane, email=jane@example.com, id=550e8400-e29b-41d4-a716-446655440001, lastName=Doe}}'
CommentPagedList:
type: object
properties:
paging:
$ref: '#/components/schemas/PagingState'
total:
type: integer
format: int32
items:
type: array
items:
$ref: '#/components/schemas/Comment'
PagingState:
type: object
properties:
has_previous_page:
type: boolean
start_cursor:
type: string
end_cursor:
type: string
has_next_page:
type: boolean
User:
type: object
properties:
lastName:
type: string
description: The user's last name
firstName:
type: string
description: The user's first name
id:
type: string
description: The user ID
format: uuid
status:
type: string
description: The user's organization status (ACTIVE, INACTIVE)
email:
type: string
description: The user's email address
format: email
jobTitle:
type: string
description: The user's job title
example: '{lastName=Doe, firstName=Jane, id=550e8400-e29b-41d4-a716-446655440000, status=ACTIVE, email=jane@example.com, jobTitle=Engineer}'
responses:
'429':
description: Too Many Requests
'422':
description: Unprocessable Entity
'404':
description: Not Found
'400':
description: Bad Request
'401':
description: Unauthorized
'403':
description: Forbidden
'500':
description: Internal Server Error
securitySchemes:
ClientCredentials:
type: oauth2
flows:
clientCredentials:
tokenUrl: /oauth/token
externalDocs:
description: Find out more about Elementum
url: https://www.elementum.com/