State Transition Logs

State change history and audit trail

List state transition logs

get

Returns a paginated list of state transition logs with comprehensive filtering options.

This endpoint provides audit trail information for all state changes in the system. Logs are automatically created whenever an object (Package, TransferOrder, etc.) transitions from one state to another.

Note: This is a read-only resource. Logs cannot be created, updated, or deleted via the API.

Authorizations
AuthorizationstringRequired

JWT-based authentication required for all endpoints.

Include the token in the Authorization header: Authorization: Bearer <token>

Query parameters
formatstring · enumOptional

Response format (json, xml, etc.)

Default: jsonPossible values:
pageinteger · min: 1Optional

Page number for pagination

Default: 1
limitinteger · min: 1 · max: 100Optional

Number of items per page

Default: 10
sortstringOptional

Sort results by field. Prefix with '-' for descending order.

Available sort fields:

  • id or -id
  • created_date or -created_date
  • modified_date or -modified_date
Default: -idExample: -created_date
old_stateintegerOptional

Filter by old state ID

Example: 1
new_stateintegerOptional

Filter by new state ID

Example: 2
old_state__namestringOptional

Filter by old state name (exact match)

Example: Waiting
new_state__namestringOptional

Filter by new state name (exact match)

Example: Preparing
old_state__enum_value__instringOptional

Filter by old state enum values (comma-separated list)

Example: 100,150
new_state__enum_value__instringOptional

Filter by new state enum values (comma-separated list)

Example: 200,300
object_idintegerOptional

Filter by related object ID

Example: 123
content_typeintegerOptional

Filter by content type ID

Example: 45
created_date__gtstring · date-timeOptional

Filter logs created after this date

Example: 2025-12-01T00:00:00Z
created_date__gtestring · date-timeOptional

Filter logs created on or after this date

Example: 2025-12-01T00:00:00Z
created_date__ltstring · date-timeOptional

Filter logs created before this date

Example: 2025-12-31T23:59:59Z
created_date__ltestring · date-timeOptional

Filter logs created on or before this date

Example: 2025-12-31T23:59:59Z
modified_date__gtstring · date-timeOptional

Filter logs modified after this date

Example: 2025-12-01T00:00:00Z
modified_date__gtestring · date-timeOptional

Filter logs modified on or after this date

Example: 2025-12-01T00:00:00Z
modified_date__ltstring · date-timeOptional

Filter logs modified before this date

Example: 2025-12-31T23:59:59Z
modified_date__ltestring · date-timeOptional

Filter logs modified on or before this date

Example: 2025-12-31T23:59:59Z
id__gtintegerOptional

Filter by ID greater than

Example: 1000
id__gteintegerOptional

Filter by ID greater than or equal to

Example: 1000
id__ltintegerOptional

Filter by ID less than

Example: 5000
id__lteintegerOptional

Filter by ID less than or equal to

Example: 5000
Responses
chevron-right
200

Successful operation

application/json
countintegerOptional

Total number of state transition logs

Example: 1250
nextstring · nullableOptional

URL to the next page of results

Example: /api/v1/oms/state-transition-logs/?page=2
previousstring · nullableOptional

URL to the previous page of results

get
/state-transition-logs/

Get state transition log by ID

get

Retrieve a specific state transition log entry by its ID.

Returns detailed information about a single state change including the old state, new state, user who triggered the change, and additional metadata in the attributes field.

Authorizations
AuthorizationstringRequired

JWT-based authentication required for all endpoints.

Include the token in the Authorization header: Authorization: Bearer <token>

Path parameters
idintegerRequired

Unique identifier of the state transition log

Example: 5432
Query parameters
formatstring · enumOptional

Response format (json, xml, etc.)

Default: jsonPossible values:
Responses
chevron-right
200

State transition log details

application/json

Represents a state transition log entry with complete nested relationship data.

This schema includes full details of the old state, new state, and user who triggered the transition. The attributes field contains additional metadata about the transition.

idintegerRead-onlyRequired

Unique identifier for the log entry

Example: 5432
attributesobject · nullableOptional

Additional metadata about the state transition.

Common fields:

  • command.slug: The command that triggered the transition (e.g., "PKG_STATE_TRANSITION")
  • command.transition_id: The ID of the state transition rule used
  • remote_user_pk: The ID of the user in a remote system
  • remote_user_mail: The email of the user in a remote system
Example: {"command":{"slug":"PKG_STATE_TRANSITION","transition_id":50},"remote_user_pk":789,"remote_user_mail":"[email protected]"}
created_datestring · date-timeRead-onlyRequired

When the transition occurred

Example: 2025-12-22T10:30:00.123456Z
object_idintegerRead-onlyRequired

ID of the object that transitioned (Package, TransferOrder, etc.)

Example: 123
content_typeintegerRead-onlyRequired

Content type ID identifying the type of object that transitioned

Example: 45
get
/state-transition-logs/{id}/

List state transition logs (simple format)

get

Returns a list of state transition logs with minimal information without nested serializers.

This endpoint is useful for lightweight data retrieval when nested relationship data is not needed. Foreign key fields return only IDs instead of full nested objects, reducing response payload size.

Note: This endpoint does not use pagination by default.

Authorizations
AuthorizationstringRequired

JWT-based authentication required for all endpoints.

Include the token in the Authorization header: Authorization: Bearer <token>

Query parameters
formatstring · enumOptional

Response format (json, xml, etc.)

Default: jsonPossible values:
sortstringOptional

Sort results by field. Prefix with '-' for descending order.

Available sort fields:

  • id or -id
  • created_date or -created_date
  • modified_date or -modified_date
Default: -idExample: -created_date
old_stateintegerOptional

Filter by old state ID

Example: 1
new_stateintegerOptional

Filter by new state ID

Example: 2
object_idintegerOptional

Filter by related object ID

Example: 123
content_typeintegerOptional

Filter by content type ID

Example: 45
created_date__gtestring · date-timeOptional

Filter logs created on or after this date

Example: 2025-12-01T00:00:00Z
created_date__ltestring · date-timeOptional

Filter logs created on or before this date

Example: 2025-12-31T23:59:59Z
Responses
chevron-right
200

Successful operation

application/json

Simplified state transition log entry without nested relationship data. Foreign key fields return only IDs for lightweight data retrieval.

idintegerOptional

Unique identifier for the log entry

Example: 5432
created_datestring · date-timeOptional

When the transition occurred

Example: 2025-12-22T10:30:00.123456Z
modified_datestring · date-timeOptional

When the log entry was last modified

Example: 2025-12-22T10:30:00.123456Z
old_stateintegerOptional

ID of the old state

Example: 1
new_stateintegerOptional

ID of the new state

Example: 2
content_typeintegerOptional

Content type ID

Example: 45
object_idintegerOptional

ID of the object that transitioned

Example: 123
userinteger · nullableOptional

ID of the user who triggered the transition

Example: 10
attributesobject · nullableOptional

Additional metadata about the transition

Example: {"command":{"slug":"PKG_STATE_TRANSITION","transition_id":50}}
get
/state-transition-logs/simple/

Last updated

Was this helpful?