OBMS API Documentation (v1.6.5)
Download OpenAPI specification:Download
E-mail: support@getobms.com License: BSL 1.1
OBMS Swagger API documentation
Authenticate user
Authenticate user and return a token
Request Body schema: application/json
string | |
password | string |
Responses
Request samples
- Payload
Content type
application/json
{- "email": "user@example.com",
- "password": "password"
}
Response samples
- 200
- 403
Content type
application/json
{- "success": true,
- "data": {
- "token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJhdWQiOiI3IiwianRpIjoiZjYzY2NlMjMyMGI0NjQ4ZTQzYzZlNDY3YzhmZWVkNDI3ODJjMDhjZGUzNWZlNWZkZWE5MmYzNDdmNWY2ZWMxYmMxM2NjNzVhMDVlMGJhNzMiLCJpYXQiOjE3NDA3Nzk0MDAuMjM1NzY1LCJuYmYiOjE3NDA3Nzk0MDAuMjM1NzY4LCJleHAiOjE3NzIzMTU0MDAuMjA5NDU5LCJzdWIiOiIzIiwic2NvcGVzIjpbXX0.cZfYgJ22uOjLsRLrbXr1eN0kXys3PPllVaQd27LyvLT_eoFTKZMEeBgnzI9DEar73HOc61t2FnokC2Y5X1fvUluN2N-K5M4BH-10cwK0I7Ch6NXHKrLww0B7lsPKoIu7nSvDWiydCY0HkzRWq-UpdODTafp6HIisF_T60sVfwKa1PxwkH4eTZ96HDo17wbIWnkHs5WX4e6z0GzxJ8QCavoZL3JzR2MUWUCGM52BICppe5EZorxW9iWHyWKs0sufUZgBLLFLqz5_Tz4RTnMAMkcimX41o-XBQeMmz1juJlRZ3LtlpOwFhy1Ixj9rkNtNz1UxMPq8fgqbMhYSgUHL1aTFT1qzrn6s0HP38bnnAsWj2V1OW4vftZF9jasvzn6yWl59Hfym4H1nUSf8iyFF9MxYZOJVFjqEwpNPZvL1zEYGETtAKeHyVzpL6ytj9xUE71LAqbTchwBLVUgCvLob1hhSkxg3-CBjHXKX_Az8nvOXiF62iw3Y1U7hjZLpYzU1HioqOkTsdwtbTyssqHYdU3OM_xr4lQkdwpHcFliwthUBdxzMWybtVxTRQUwQ-EjuJt3GRN4xKlWfkuDEHPWGxXr8Huz3lEtFc1q5fMex9i1fD0egS6wHw6BEBxAqJxDCfpbo7swRtrnvdDKBrsMId6dn6wxEQJNBqOvp_HnKqmEI",
- "name": "API"
}
}
Response samples
- 200
- 403
Content type
application/json
{- "success": true,
- "message": "Contract usage tracker retrieved successfully.",
- "data": [
- {
- "id": 1,
- "name": "Usage Tracker",
- "description": "Usage Tracker Description",
- "vat_type": "VAT Type",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
]
}
Create a new contract usage tracker
Create a new contract usage tracker
Authorizations:
bearerAuth
Request Body schema: application/json
name | string |
description | string |
vat_type | string |
Responses
Request samples
- Payload
Content type
application/json
{- "name": "Contract Usage Tracker",
- "description": "Contract usage tracker description",
- "vat_type": "VAT type"
}
Response samples
- 201
- 403
- 422
Content type
application/json
{- "success": true,
- "message": "Contract usage tracker created successfully.",
- "data": {
- "id": 1,
- "name": "Usage Tracker",
- "description": "Usage Tracker Description",
- "vat_type": "VAT Type",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
Get a contract usage tracker by ID
Get a contract usage tracker by ID
Authorizations:
bearerAuth
path Parameters
id required | any ID of the contract usage tracker |
Responses
Response samples
- 200
- 403
- 404
Content type
application/json
{- "success": true,
- "message": "Contract usage tracker retrieved successfully.",
- "data": {
- "id": 1,
- "name": "Usage Tracker",
- "description": "Usage Tracker Description",
- "vat_type": "VAT Type",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
Update a contract usage tracker by ID
Update a contract usage tracker by ID
Authorizations:
bearerAuth
path Parameters
id required | any ID of the contract usage tracker |
Request Body schema: application/json
name | string |
description | string |
vat_type | string |
Responses
Request samples
- Payload
Content type
application/json
{- "name": "Contract Usage Tracker",
- "description": "Contract usage tracker description",
- "vat_type": "VAT type"
}
Response samples
- 200
- 403
- 422
Content type
application/json
{- "success": true,
- "message": "Contract usage tracker updated successfully.",
- "data": {
- "id": 1,
- "name": "Usage Tracker",
- "description": "Usage Tracker Description",
- "vat_type": "VAT Type",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
Delete a contract usage tracker by ID
Delete a contract usage tracker by ID
Authorizations:
bearerAuth
path Parameters
id required | any ID of the contract usage tracker |
Responses
Response samples
- 200
- 403
- 404
Content type
application/json
{- "success": true,
- "message": "Contract usage tracker deleted successfully."
}
Create a new contract usage tracker instance
Create a new contract usage tracker instance
Authorizations:
bearerAuth
Request Body schema: application/json
contract_id | integer |
tracker_id | integer |
contract_position_id | integer |
Responses
Request samples
- Payload
Content type
application/json
{- "contract_id": 1,
- "tracker_id": 1,
- "contract_position_id": 1
}
Response samples
- 403
- 422
Content type
application/json
{- "success": false,
- "message": "Forbidden"
}
Update a contract usage tracker instance by ID
Update a contract usage tracker instance by ID
Authorizations:
bearerAuth
path Parameters
id required | any ID of the contract usage tracker instance |
Request Body schema: application/json
contract_id | integer |
tracker_id | integer |
contract_position_id | integer |
Responses
Request samples
- Payload
Content type
application/json
{- "contract_id": 1,
- "tracker_id": 1,
- "contract_position_id": 1
}
Response samples
- 403
- 422
Content type
application/json
{- "success": false,
- "message": "Forbidden"
}
Delete a contract usage tracker instance by ID
Delete a contract usage tracker instance by ID
Authorizations:
bearerAuth
path Parameters
id required | any ID of the contract usage tracker instance |
Responses
Response samples
- 200
- 403
- 404
Content type
application/json
{- "success": true,
- "message": "Contract usage tracker instance deleted successfully."
}
Create a new usage tracker item
Create a new usage tracker item
Authorizations:
bearerAuth
Request Body schema: application/json
tracker_id | integer |
type | string |
process | string |
round | string |
step | integer |
amount | number |
Responses
Request samples
- Payload
Content type
application/json
{- "tracker_id": 1,
- "type": "type",
- "process": "equals",
- "round": "none",
- "step": 1,
- "amount": 100
}
Response samples
- 403
- 422
Content type
application/json
{- "success": false,
- "message": "Forbidden"
}
Update a usage tracker item by ID
Update a usage tracker item by ID
Authorizations:
bearerAuth
path Parameters
id required | any ID of the usage tracker item |
Request Body schema: application/json
tracker_id | integer |
type | string |
process | string |
round | string |
step | integer |
amount | number |
Responses
Request samples
- Payload
Content type
application/json
{- "tracker_id": 1,
- "type": "type",
- "process": "equals",
- "round": "none",
- "step": 1,
- "amount": 100
}
Response samples
- 403
- 422
Content type
application/json
{- "success": false,
- "message": "Forbidden"
}