OriginAddress - OgnianApostolov/builderly-api-docs GitHub Wiki

Model

OriginAddress originAddress{
    "_id": {
        "autogenerated": "true"
    },
    "title": {
        "type": "string",
        "required": "true",
        "unique": "true"
    },
    "createdAt": {
        "autogenerated": "true"
    },
    "updatedAt": {
        "autogenerated": "true"
    }
}

Methods

Create new

POST /origin-address req.body required

method: 'POST'
{
    url: 'https://{{your-builderly-domain}}/origin-address',
    headers: {
        'Authorization': 'Bearer ' + token
    },
    json: true,
    body: {}
}

Responses Success - status 201

{}

Error - status 500

{
    error_message
}

Retrieve multiple

GET /origin-address

method: 'GET'
{
    url: 'https://{{your-builderly-domain}}/origin_address',
    headers: {},
    json: true,
    body: {}
}

Responses Success - status 200

[originAddress]

Error - status 500

{
    error_message
}
  • Example usages: /origin-address - Get all OriginAddress records

Retrieve single

GET /origin-address/:id

method: 'GET'
{
    url: 'https://{{your-builderly-domain}}/origin-address/{{origin-address._id}}',
    headers: {},
    json: true,
    body: {}
}

Responses Success - status 200

{ origin-address}

Error - status 500

{
    error_message
}
  • Example usages: /origin-address/:id - Retrives a specific origin address

Update single

PATCH /origin-address/:id?

method: 'PATCH'
{
    url: 'https://{{your-builderly-domain}}/origin-address/{{origin-address._id}}',
    headers: {
        'Authorization': 'Bearer ' + token
    },
    json: true,
    body: {}
}

Responses Success - status 200

{ origin-address }

Error - status 400

{
    error_message
}

Not found - status 404

{}

Delete single

DELETE /origin-address/:id

method: 'DELETE'
{
    url: 'https://{{your-builderly-domain}}/origin-address/{{origin-address._id}}',
    headers: {
        'Authorization': 'Bearer ' + token
    },
    json: true,
    body: {}
}

Responses Success - status 200

{ origin-address }

Not found - status 404

{}

Error - status 500

{
    error_message
}