NAV
bash javascript

Info

Welcome to the generated API reference.

Attachments Requests

API calls for managing Attachments

Available Entity Types:

Name Description
calendar
customer
event
person
poi
product
registration

GET Attachments


Requires authentication Returns a list with Attachments

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/attachments? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/attachments");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "attachment",
            "id": 46,
            "attributes": {
                "created_at": "2019-10-08T11:36:45+00:00",
                "updated_at": "2019-10-08T11:36:45+00:00",
                "deleted_at": null,
                "entity_id": 1,
                "entity_type": "poi",
                "category": "file",
                "external_id": "22aff271-0178-454f-b486-943eecc1357d"
            },
            "relationships": {
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi\/1\/poi"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/attachment\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/attachments",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/attachments?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/attachments?page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "filter.entity_type": [
            "The selected filter.entity type is invalid."
        ]
    }
}

HTTP Request

GET api/v1/attachments

Query Parameters

Parameter Status Description
filter[entity_type] optional Search on specific related entity_type.
filter[entity_id] optional Search on specific related entity_id.
filter[category] optional Search on specific category.
filter[external_id] optional Search on specific category external_id.

POST Attachments


Requires authentication Creates a specific Attachment

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/attachments" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"attachment","attributes":{"category":"file","external_id":"22aff271-0178-454f-b486-943eecc1357d","thumbnail":"aliquam"},"relationships":{"entity":{"data":{"id":2}},"related-poi":{"data":{"type":"poi"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/attachments");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "attachment",
        "attributes": {
            "category": "file",
            "external_id": "22aff271-0178-454f-b486-943eecc1357d",
            "thumbnail": "aliquam"
        },
        "relationships": {
            "entity": {
                "data": {
                    "id": 2
                }
            },
            "related-poi": {
                "data": {
                    "type": "poi"
                }
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "attachment",
        "id": 35,
        "attributes": {
            "created_at": "2019-10-09T14:06:36+00:00",
            "updated_at": "2019-10-09T14:06:36+00:00",
            "deleted_at": null,
            "entity_id": 1,
            "entity_type": "App\\Models\\Eloquent\\Poi",
            "category": "file",
            "external_id": "22aff271-0178-454f-b486-943eecc1357d"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/attachments\/35\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/attachment\/35"
        }
    },
    "links": []
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.external_id": [
            "The data.attributes.external id field is required."
        ],
        "data.relationships.entity.data.id": [
            "The data.relationships.entity.data.id field is required."
        ],
        "data.relationships.entity.data.type": [
            "The data.relationships.entity.data.type field is required."
        ]
    }
}

HTTP Request

POST api/v1/attachments

Body Parameters

Parameter Type Status Description
data.type string optional required.
data.attributes.category string optional required.
data.attributes.external_id string. optional
data.attributes.thumbnail string required base64encoded string.
data.relationships.entity.data.id integer required id.
data.relationships.related-poi.data.type string optional required.

PATCH Attachment


Requires authentication Updates a specific Attachment

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/attachments/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"attachment","attributes":{"category":"file","external_id":"22aff271-0178-454f-b486-943eecc1357d","thumbnail":"aut"},"relationships":{"entity":{"data":{"id":2,"type":"poi"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/attachments/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "attachment",
        "attributes": {
            "category": "file",
            "external_id": "22aff271-0178-454f-b486-943eecc1357d",
            "thumbnail": "aut"
        },
        "relationships": {
            "entity": {
                "data": {
                    "id": 2,
                    "type": "poi"
                }
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "attachment",
        "id": 1,
        "attributes": {
            "created_at": "2019-10-08T13:09:09+00:00",
            "updated_at": "2019-10-09T07:51:40+00:00",
            "deleted_at": null,
            "entity_id": 3,
            "entity_type": "poi",
            "category": "file",
            "external_id": "22aff271-0178-454f-b486-943eecc1357d"
        },
        "relationships": {
            "entity": {
                "data": {
                    "type": "poi",
                    "id": 2
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi\/1\/entity"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/attachment\/87"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The data.id field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/attachments/{attachment}

Body Parameters

Parameter Type Status Description
data.type string optional required.
data.attributes.category string optional required.
data.attributes.external_id string. optional
data.attributes.thumbnail string required base64encoded string.
data.relationships.entity.data.id integer required id.
data.relationships.entity.data.type string optional required.

DELETE a file.

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/attachments/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/attachments/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v1/attachments/{attachment}

GET Attachments from Event


Requires authentication Returns Attachments linked to a specific event

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/events/1/attachments? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/events/1/attachments");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "attachment",
            "id": 108,
            "attributes": {
                "created_at": "2019-10-09T07:43:03+00:00",
                "updated_at": "2019-10-09T07:43:03+00:00",
                "deleted_at": null,
                "entity_id": 1,
                "entity_type": "product",
                "category": "file",
                "external_id": "22aff271-0178-454f-b486-943eecc1357d"
            },
            "relationships": {
                "entity": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/product\/108\/entity"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/attachment\/108"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/1\/attachments",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/products\/1\/attachments?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/products\/1\/attachments?page[number]=1"
    }
}

HTTP Request

GET api/v1/events/{event}/attachments

Query Parameters

Parameter Status Description
filter[entity_type] optional Search on specific related entity_type.
filter[entity_id] optional Search on specific related entity_id.
filter[category] optional Search on specific category.
filter[external_id] optional Search on specific category external_id.

GET Attachments from Person


Requires authentication Returns Attachments linked to a specific person

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/persons/1/attachments? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/persons/1/attachments");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "attachment",
            "id": 108,
            "attributes": {
                "created_at": "2019-10-09T07:43:03+00:00",
                "updated_at": "2019-10-09T07:43:03+00:00",
                "deleted_at": null,
                "entity_id": 1,
                "entity_type": "event",
                "category": "file",
                "external_id": "22aff271-0178-454f-b486-943eecc1357d"
            },
            "relationships": {
                "entity": {
                    "data": {
                        "type": "event",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/event\/108\/entity"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/attachment\/108"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/attachments",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/attachments?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/attachments?page[number]=1"
    }
}

HTTP Request

GET api/v1/persons/{person}/attachments

Query Parameters

Parameter Status Description
filter[entity_type] optional Search on specific related entity_type.
filter[entity_id] optional Search on specific related entity_id.
filter[category] optional Search on specific category.
filter[external_id] optional Search on specific category external_id.

GET Attachments from Poi


Requires authentication Returns Attachments linked to a specific poi

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/attachments? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/attachments");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "attachment",
            "id": 108,
            "attributes": {
                "created_at": "2019-10-09T07:43:03+00:00",
                "updated_at": "2019-10-09T07:43:03+00:00",
                "deleted_at": null,
                "entity_id": 1,
                "entity_type": "poi",
                "category": "file",
                "external_id": "22aff271-0178-454f-b486-943eecc1357d"
            },
            "relationships": {
                "entity": {
                    "data": {
                        "type": "poi",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi\/108\/entity"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/attachment\/108"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/attachments",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/attachments?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/attachments?page[number]=1"
    }
}

HTTP Request

GET api/v1/pois/{poi}/attachments

Query Parameters

Parameter Status Description
filter[entity_type] optional Search on specific related entity_type.
filter[entity_id] optional Search on specific related entity_id.
filter[category] optional Search on specific category.
filter[external_id] optional Search on specific category external_id.

GET Attachments from Poi Related Poi


Requires authentication Returns Attachments linked to a specific poi related poi

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1/attachments? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1/attachments");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "attachment",
            "id": 108,
            "attributes": {
                "created_at": "2019-10-09T07:43:03+00:00",
                "updated_at": "2019-10-09T07:43:03+00:00",
                "deleted_at": null,
                "entity_id": 1,
                "entity_type": "poi",
                "category": "file",
                "external_id": "22aff271-0178-454f-b486-943eecc1357d"
            },
            "relationships": {
                "entity": {
                    "data": {
                        "type": "poi",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi\/108\/entity"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/attachment\/108"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/attachments",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/attachments?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/attachments?page[number]=1"
    }
}

HTTP Request

GET api/v1/poi-related-pois/{poiRelatedPois}/attachments

Query Parameters

Parameter Status Description
filter[entity_type] optional Search on specific related entity_type.
filter[entity_id] optional Search on specific related entity_id.
filter[category] optional Search on specific category.
filter[external_id] optional Search on specific category external_id.

GET Attachments from Product Related Poi


Requires authentication Returns Attachments linked to a specific poi related poi

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois/1/attachments? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois/1/attachments");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "attachment",
            "id": 108,
            "attributes": {
                "created_at": "2019-10-09T07:43:03+00:00",
                "updated_at": "2019-10-09T07:43:03+00:00",
                "deleted_at": null,
                "entity_id": 1,
                "entity_type": "poi",
                "category": "file",
                "external_id": "22aff271-0178-454f-b486-943eecc1357d"
            },
            "relationships": {
                "entity": {
                    "data": {
                        "type": "poi",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi\/108\/entity"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/attachment\/108"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/attachments",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/attachments?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/attachments?page[number]=1"
    }
}

HTTP Request

GET api/v1/product-related-pois/{productRelatedPois}/attachments

Query Parameters

Parameter Status Description
filter[entity_type] optional Search on specific related entity_type.
filter[entity_id] optional Search on specific related entity_id.
filter[category] optional Search on specific category.
filter[external_id] optional Search on specific category external_id.

GET Attachments from Product


Requires authentication Returns Attachments linked to a specific Product

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/products/1/attachments? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/products/1/attachments");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "attachment",
            "id": 108,
            "attributes": {
                "created_at": "2019-10-09T07:43:03+00:00",
                "updated_at": "2019-10-09T07:43:03+00:00",
                "deleted_at": null,
                "entity_id": 1,
                "entity_type": "product",
                "category": "file",
                "external_id": "22aff271-0178-454f-b486-943eecc1357d"
            },
            "relationships": {
                "entity": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/product\/108\/entity"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/attachment\/108"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/1\/attachments",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/products\/1\/attachments?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/products\/1\/attachments?page[number]=1"
    }
}

HTTP Request

GET api/v1/products/{product}/attachments

Query Parameters

Parameter Status Description
filter[entity_type] optional Search on specific related entity_type.
filter[entity_id] optional Search on specific related entity_id.
filter[category] optional Search on specific category.
filter[external_id] optional Search on specific category external_id.

Billing Information requests

API calls for retrieving and managing BillingInformation resources

Class BillingInformationController

GET Billing Information resources


Requires authentication Returns a paginated response of BillingInformation entities.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/billing-information? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/billing-information");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 4,
            "total": 4,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "billing-information",
            "id": 259,
            "attributes": {
                "created_at": "2020-05-19 04:17:45",
                "updated_at": "2020-05-19 04:17:45",
                "deleted_at": null,
                "id": 259,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": {
                "status": {
                    "data": {
                        "id": 8152,
                        "type": "option",
                        "attributes": {
                            "category": "status_billing_information",
                            "name": "Non facturable (en lieu de taxes)",
                            "parent_id": null,
                            "link_id": 7318
                        }
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/259\/status"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/259"
            }
        },
        {
            "type": "billing-information",
            "id": 260,
            "attributes": {
                "created_at": "2020-05-19 04:17:45",
                "updated_at": "2020-05-19 04:17:45",
                "deleted_at": null,
                "id": 260,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": {
                "status": {
                    "data": {
                        "id": 8153,
                        "type": "option",
                        "attributes": {
                            "category": "status_billing_information",
                            "name": "Non facturable (à la valeur)",
                            "parent_id": null,
                            "link_id": 7319
                        }
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/260\/status"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/260"
            }
        },
        {
            "type": "billing-information",
            "id": 261,
            "attributes": {
                "created_at": "2020-05-19 04:17:45",
                "updated_at": "2020-05-19 04:17:45",
                "deleted_at": null,
                "id": 261,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": {
                "status": {
                    "data": {
                        "id": 8154,
                        "type": "option",
                        "attributes": {
                            "category": "status_billing_information",
                            "name": "Non facturable (en lieu de taxes)",
                            "parent_id": null,
                            "link_id": 7320
                        }
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/261\/status"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/261"
            }
        },
        {
            "type": "billing-information",
            "id": 262,
            "attributes": {
                "created_at": "2020-05-19 04:17:45",
                "updated_at": "2020-05-19 04:17:45",
                "deleted_at": null,
                "id": 262,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": {
                "status": {
                    "data": {
                        "id": 8155,
                        "type": "option",
                        "attributes": {
                            "category": "status_billing_information",
                            "name": "Non facturable (en lieu de taxes)",
                            "parent_id": null,
                            "link_id": 7321
                        }
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/262\/status"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/262"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information?page%5Bnumber%5D=1"
    }
}

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/billing-information

Query Parameters

Parameter Status Description
filter[poi_id] optional Filter on resources related to 1 or multiple Poi-resources.

GET Billing Information


Requires authentication Returns a single Billing Information resource

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/billing-information/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/billing-information/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "billing-information",
        "id": 299,
        "attributes": {
            "created_at": "2020-05-19 04:20:05",
            "updated_at": "2020-05-19 04:20:05",
            "deleted_at": null,
            "id": 299,
            "from": null,
            "until": null,
            "properties": []
        },
        "relationships": {
            "status": {
                "data": {
                    "id": 8202,
                    "type": "option",
                    "attributes": {
                        "category": "status_billing_information",
                        "name": "Non facturable (à la valeur)",
                        "parent_id": null,
                        "link_id": 7368
                    }
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/299\/status"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/299"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/billing-information/{billingInformation}

POST Billing Information

Endpoint to create a single Billing Information entity.

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/billing-information" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/billing-information");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "billing-information",
        "id": 332,
        "attributes": {
            "created_at": "2020-05-19 04:21:07",
            "updated_at": "2020-05-19 04:21:07",
            "deleted_at": null,
            "properties": [],
            "from": "2020-05-18T04:21:07.219881Z",
            "until": null,
            "id": 332
        },
        "relationships": {
            "status": {
                "data": {
                    "id": 8247,
                    "type": "option",
                    "attributes": {
                        "category": "status_billing_information",
                        "name": "Non facturable (à la valeur)",
                        "parent_id": null,
                        "link_id": 7413
                    }
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/332\/status"
                }
            },
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 22907
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/332\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/332"
        }
    },
    "links": []
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ],
        "data.relationships": [
            "The data.relationships field is required."
        ],
        "data.relationships.entity": [
            "The data.relationships.entity field is required."
        ],
        "data.relationships.entity.data": [
            "The data.relationships.entity.data field is required."
        ],
        "data.relationships.entity.data.type": [
            "The data.relationships.entity.data.type field is required."
        ],
        "data.relationships.entity.data.id": [
            "The data.relationships.entity.data.id field is required."
        ],
        "data.relationships.status": [
            "The data.relationships.status field is required."
        ],
        "data.relationships.status.data": [
            "The data.relationships.status.data field is required."
        ],
        "data.relationships.status.data.type": [
            "The data.relationships.status.data.type field is required."
        ],
        "data.relationships.status.data.id": [
            "The data.relationships.status.data.id field is required."
        ]
    }
}

HTTP Request

POST api/v1/billing-information

PATCH Billing Information

Endpoint to update a specific Billing Information entity.

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/billing-information/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/billing-information/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "PATCH",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "billing-information",
        "id": 368,
        "attributes": {
            "created_at": "2020-05-19 04:21:56",
            "updated_at": "2020-05-19 04:21:56",
            "deleted_at": null,
            "id": 368,
            "from": "2020-05-19T04:21:56.767501Z",
            "until": "2020-05-21T04:21:56.767507Z",
            "properties": []
        },
        "relationships": {
            "status": {
                "data": {
                    "id": 8296,
                    "type": "option",
                    "attributes": {
                        "category": "status_billing_information",
                        "name": "Non facturable (à la valeur)",
                        "parent_id": null,
                        "link_id": 7462
                    }
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/368\/status"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/368"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The data.id field is required."
        ],
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/billing-information/{billingInformation}

DELETE Billing Information entity

Endpoint to destroy a specific Billing Information entity.

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/billing-information/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/billing-information/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v1/billing-information/{billingInformation}

Calendar

API calls for managing Calendars

Available categories:

Name Description
bin_product_calendar
bin_product_sub_calendar
action_event_calendar
ciaccess_product_calendar
other_garbage_event_calendar
other_garbage_event_sub_calendar

GET Calendars


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/calendars? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendars");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 7,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "calendar",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-09T14:01:39+00:00",
                "updated_at": "2018-04-09T12:40:29+00:00",
                "deleted_at": null,
                "tags": [],
                "category": "bin_product_calendar",
                "link_id": null,
                "name": "GFT route",
                "from": "2016-03-09",
                "until": "2018-12-31",
                "dates": [
                    "2016-03-14",
                    "2018-12-24",
                    "2018-12-31"
                ],
                "properties": []
            },
            "relationships": {
                "profiles": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 93
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles"
                    }
                },
                "pois": {
                    "link": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/calendars?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/calendars?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/calendars?size=1&page[number]=7"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "filter.category": [
            "The selected filter.category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/calendars

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific calendar category.
filter[name] optional Find Calendar with given name.
filter[from] optional Calendars from a certain date.
filter[from_between] optional Calendars from between two dates (inclusive).
filter[until] optional Calendars until a certain date.
filter[until_between] optional Calendars until between two dates (inclusive).
filter[profile] optional Find Calendars for given Profile.
filter[poi] optional Find Calendars for a given Poi.

POST Calendars


Requires authentication

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/calendars" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"calendar","attributes":{"category":"action_event_calendar","name":"Example calendar","from":"2019-05-10","until":"2019-08-20","dates":[]},"relationships":{"parent":{"data":{"id":1,"type":"calendar"}},"profiles":{"data":[{"id":2,"type":"profile"}]},"pois":{"data":[{"id":3,"type":"poi"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendars");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "calendar",
        "attributes": {
            "category": "action_event_calendar",
            "name": "Example calendar",
            "from": "2019-05-10",
            "until": "2019-08-20",
            "dates": []
        },
        "relationships": {
            "parent": {
                "data": {
                    "id": 1,
                    "type": "calendar"
                }
            },
            "profiles": {
                "data": [
                    {
                        "id": 2,
                        "type": "profile"
                    }
                ]
            },
            "pois": {
                "data": [
                    {
                        "id": 3,
                        "type": "poi"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "calendar",
        "id": 1,
        "attributes": {
            "created_at": "2016-03-09T14:01:39+00:00",
            "updated_at": "2018-04-09T12:40:29+00:00",
            "deleted_at": null,
            "link_id": null,
            "tags": [],
            "category": "bin_product_calendar",
            "name": "GFT route",
            "from": "2016-03-09",
            "until": "2018-12-31",
            "dates": [],
            "properties": []
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": 93
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles"
                }
            },
            "pois": {
                "link": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1"
        }
    },
    "links": []
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.name": [
            "The data.attributes.name field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ],
        "data.attributes.until": [
            "The data.attributes.until date field is required."
        ],
        "data.relationships.profiles.data": [
            "The data.relationships.profiles.data field is required."
        ]
    }
}

HTTP Request

POST api/v1/calendars

Body Parameters

Parameter Type Status Description
data.type string required Type must be calendar.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.name string required Name of this calendar.
data.attributes.from date required From date.
data.attributes.until date required Until date.
data.attributes.dates array required Until date.
data.relationships.parent.data.id integer optional optional Parent calendar.
data.relationships.parent.data.type string optional optional Must be calendar.
data.relationships.profiles.data.*.id integer optional optional Profile id.
data.relationships.profiles.data.*.type string optional optional Profile type must be profile.
data.relationships.pois.data.*.id integer optional optional Poi id.
data.relationships.pois.data.*.type string optional optional Poi type must be poi.

GET Calendar


Requires authentication returns a specific calendar

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "calendar",
        "id": 1,
        "attributes": {
            "created_at": "2016-03-09T14:01:39+00:00",
            "updated_at": "2018-04-09T12:40:29+00:00",
            "deleted_at": null,
            "link_id": null,
            "tags": [],
            "category": "bin_product_calendar",
            "name": "GFT route",
            "from": "2016-03-09",
            "until": "2018-12-31",
            "dates": [
                "2016-03-14",
                "2018-12-24",
                "2018-12-31"
            ],
            "properties": []
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": 93
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles"
                }
            },
            "pois": {
                "link": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "filter.category": [
            "The selected filter.category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/calendars/{calendar}

GET the list of children from a specific Calendar


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/children" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/children");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "calendar",
            "id": 10,
            "attributes": {
                "created_at": "2019-01-01T00:00:00+00:00",
                "updated_at": "2019-01-01T00:00:00+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "bin_product_sub_calendar",
                "name": "GFT sub route",
                "from_date": "2019-01-01",
                "until_date": "2019-01-31",
                "dates": [
                    "2019-01-07",
                    "2019-01-14",
                    "2019-01-21",
                    "2019-01-28"
                ],
                "properties": []
            },
            "relationships": {
                "parent": {
                    "data": {
                        "type": "calendar",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1860\/parent"
                    }
                },
                "profiles": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 93
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles"
                    }
                },
                "pois": {
                    "link": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/children?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/children?size=1&page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/children?size=1&page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "filter.category": [
            "The selected filter.category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/calendars/{calendar}/children

GET Calendar parent


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/parent? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/parent");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "calendar",
        "id": 1,
        "attributes": {
            "created_at": "2016-03-09T14:02:36+00:00",
            "updated_at": "2018-05-17T08:58:44+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "bin_product_calendar",
            "name": "REST route",
            "from_date": "2016-03-09",
            "until_date": "2018-12-31",
            "dates": [
                "2016-03-11",
                "2016-03-18",
                "2016-03-25"
            ],
            "properties": []
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": 90
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/2\/profiles"
                }
            },
            "pois": {
                "link": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/2\/pois"
                }
            },
            "children": {
                "data": [
                    {
                        "type": "calendar",
                        "id": 8
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/2\/children"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/2"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/calendars/{calendar}/parent

Query Parameters

Parameter Status Description
filter[id] optional search for specific id or ids.
filter[category] optional filter on a category.
filter[name] optional filter on specific name.
filter[from_date] optional filter on specific from date.
filter[until_date] optional filter on specific until date.
filter[link_id] optional filter on specific link id or link ids.
filter[profile] optional filter on specific profile id or profile ids.
filter[poi] optional filter on specific poi id or poi ids.
filter[geo-location] optional filter on specific geo location id or geo location ids.

PATCH Calendar parent


Requires authentication updates a specific calendar parent

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/parent" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"calendar","id":1,"attributes":{"category":"action_event_calendar","name":"Example calendar","from_date":"2019-05-10","until_date":"2019-08-20","dates":[]},"relationships":{"parent":{"data":{"id":1,"type":"calendar"}},"profiles":{"data":[{"id":2,"type":"profile"}]},"pois":{"data":[{"id":3,"type":"poi"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/parent");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "calendar",
        "id": 1,
        "attributes": {
            "category": "action_event_calendar",
            "name": "Example calendar",
            "from_date": "2019-05-10",
            "until_date": "2019-08-20",
            "dates": []
        },
        "relationships": {
            "parent": {
                "data": {
                    "id": 1,
                    "type": "calendar"
                }
            },
            "profiles": {
                "data": [
                    {
                        "id": 2,
                        "type": "profile"
                    }
                ]
            },
            "pois": {
                "data": [
                    {
                        "id": 3,
                        "type": "poi"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "calendar",
        "id": 1,
        "attributes": {
            "created_at": "2016-03-09T14:01:39+00:00",
            "updated_at": "2018-04-09T12:40:29+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "bin_product_calendar",
            "name": "GFT route",
            "from_date": "2016-03-09",
            "until_date": "2018-12-31",
            "dates": [
                "2016-03-14"
            ],
            "properties": []
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": 93
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles"
                }
            },
            "pois": {
                "link": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois"
                }
            },
            "children": {
                "data": [
                    {
                        "type": "calendar",
                        "id": 8
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/children"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The data.id field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.name": [
            "The data.attributes.name field is required."
        ],
        "data.attributes.from_date": [
            "The data.attributes.from date field is required."
        ],
        "data.attributes.until_date": [
            "The data.attributes.until date field is required."
        ],
        "data.relationships.profiles.data": [
            "The data.relationships.profiles.data field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/calendars/{calendar}/parent

Body Parameters

Parameter Type Status Description
data.type string required Type must be calendar.
data.id integer required The id must match the url id.
data.attributes.category string optional optional One of the categories mentioned at the top of this page.
data.attributes.name string optional optional Name of this calendar.
data.attributes.from_date date optional optional From date.
data.attributes.until_date date optional optional Until date.
data.attributes.dates array optional optional Until date.
data.relationships.parent.data.id integer optional optional Parent calendar.
data.relationships.parent.data.type string optional optional Must be calendar.
data.relationships.profiles.data.*.id integer optional optional Profile id.
data.relationships.profiles.data.*.type string optional optional Profile type must be profile.
data.relationships.pois.data.*.id integer optional optional Poi id.
data.relationships.pois.data.*.type string optional optional Poi type must be poi.

PATCH Calendar


Requires authentication updates a specific calendar

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"calendar","id":1,"attributes":{"category":"action_event_calendar","name":"Example calendar","from":"2019-05-10","until":"2019-08-20","dates":[]},"relationships":{"parent":{"data":{"id":1,"type":"calendar"}},"profiles":{"data":[{"id":2,"type":"profile"}]},"pois":{"data":[{"id":3,"type":"poi"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "calendar",
        "id": 1,
        "attributes": {
            "category": "action_event_calendar",
            "name": "Example calendar",
            "from": "2019-05-10",
            "until": "2019-08-20",
            "dates": []
        },
        "relationships": {
            "parent": {
                "data": {
                    "id": 1,
                    "type": "calendar"
                }
            },
            "profiles": {
                "data": [
                    {
                        "id": 2,
                        "type": "profile"
                    }
                ]
            },
            "pois": {
                "data": [
                    {
                        "id": 3,
                        "type": "poi"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "calendar",
        "id": 1,
        "attributes": {
            "created_at": "2016-03-09T14:01:39+00:00",
            "updated_at": "2018-04-09T12:40:29+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "bin_product_calendar",
            "name": "GFT route",
            "from": "2016-03-09",
            "until": "2018-12-31",
            "dates": [],
            "properties": []
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": 93
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles"
                }
            },
            "pois": {
                "link": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1"
        }
    },
    "links": []
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.name": [
            "The data.attributes.name field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from date field is required."
        ],
        "data.attributes.until": [
            "The data.attributes.until date field is required."
        ],
        "data.relationships.profiles.data": [
            "The data.relationships.profiles.data field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/calendars/{calendar}

Body Parameters

Parameter Type Status Description
data.type string required Type must be calendar.
data.id integer required The id must match the url id.
data.attributes.category string optional optional One of the categories mentioned at the top of this page.
data.attributes.name string optional optional Name of this calendar.
data.attributes.from date optional optional From date.
data.attributes.until date optional optional Until date.
data.attributes.dates array optional optional Until date.
data.relationships.parent.data.id integer optional optional Parent calendar.
data.relationships.parent.data.type string optional optional Must be calendar.
data.relationships.profiles.data.*.id integer optional optional Profile id.
data.relationships.profiles.data.*.type string optional optional Profile type must be profile.
data.relationships.pois.data.*.id integer optional optional Poi id.
data.relationships.pois.data.*.type string optional optional Poi type must be poi.

GET Calendars from Poi


Requires authentication returns calendars linked to a specific poi

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/calendars? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/calendars");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 7,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "calendar",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-09T14:01:39+00:00",
                "updated_at": "2018-04-09T12:40:29+00:00",
                "deleted_at": null,
                "tags": [],
                "category": "bin_product_calendar",
                "name": "GFT route",
                "from": "2016-03-09",
                "until": "2018-12-31",
                "dates": [
                    "2016-03-14",
                    "2018-12-24",
                    "2018-12-31"
                ],
                "properties": []
            },
            "relationships": {
                "profiles": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 93
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles"
                    }
                },
                "pois": {
                    "link": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/calendars\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/calendars?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/calendars?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/calendars?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/calendars?size=1&page[number]=7"
    }
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "filter.category": [
            "The selected filter.category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/pois/{poi}/calendars

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific calendar category.
filter[name] optional Find Calendar with given name.
filter[from] optional Calendars from a certain date.
filter[from_between] optional Calendars from between two dates (inclusive).
filter[until] optional Calendars until a certain date.
filter[until_between] optional Calendars until between two dates (inclusive).
filter[profile] optional Find Calendars for given Profile.

GET Calendars from Profile


Requires authentication returns calendars linked to a specific profile

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/profiles/1/calendars? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/profiles/1/calendars");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 7,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "calendar",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-09T14:01:39+00:00",
                "updated_at": "2018-04-09T12:40:29+00:00",
                "deleted_at": null,
                "tags": [],
                "category": "bin_product_calendar",
                "name": "GFT route",
                "from": "2016-03-09",
                "until": "2018-12-31",
                "dates": [
                    "2016-03-14",
                    "2018-12-24",
                    "2018-12-31"
                ],
                "properties": []
            },
            "relationships": {
                "profiles": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 93
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles"
                    }
                },
                "pois": {
                    "link": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/calendars\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/93\/calendars?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/93\/calendars?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/93\/calendars?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/93\/calendars?size=1&page[number]=7"
    }
}

HTTP Request

GET api/v1/profiles/{profile}/calendars

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific calendar category.
filter[name] optional Find Calendar with given name.
filter[from] optional Calendars from a certain date.
filter[from_between] optional Calendars from between two dates (inclusive).
filter[until] optional Calendars until a certain date.
filter[until_between] optional Calendars until between two dates (inclusive).
filter[poi] optional Find Calendars for a given Poi.

CalendarDateHistory

API calls for managing CalendarDateHistory

GET CalendarDateHistory


Requires authentication Fetch history list.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates-status-history? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates-status-history");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 7,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "calendar_date_status_history",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-14T00:00:00+00:00",
                "updated_at": "2016-03-14T00:00:00+00:00",
                "deleted_at": null,
                "id": 1,
                "from": "2016-03-14T00:00:00+00:00",
                "status": "open",
                "calendar_id": null
            },
            "relationships": {
                "calendar_date": {
                    "data": {
                        "type": "calendar_date",
                        "id": 1
                    },
                    "links": {
                        "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates-status-history",
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates\/1"
                    }
                },
                "calendar_dates_status_history": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_dates\/1\/calendar_dates_status_history"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_date_status_history\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_date_status_history?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_date_status_history?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_date_status_history?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_date_status_history?size=1&page[number]=7"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/calendar-dates-status-history

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[status] optional Filter on specific calendar date status.
filter[from] optional Calendar history on a certain date.
filter[calendar_date] optional Calendars on a certain date.
filter[from_min] optional Calendar history from a date until now.
filter[from_max] optional Calendar history from the beginning of time until the given date.
filter[on_date] optional The Calendar history status history that is active on the given date.
filter[event] optional Find the CalendarDate status history with a specific CalendarDate.

POST CalendarDateHistory


Requires authentication Create a new calendar date history.

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates-status-history" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"calendar_date_status_history","attributes":{"from":"2019-06-06T00:00:00+00:00","status":"open"},"relationships":{"calendar_date":{"data":{"id":1,"type":"calendar_date"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates-status-history");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "calendar_date_status_history",
        "attributes": {
            "from": "2019-06-06T00:00:00+00:00",
            "status": "open"
        },
        "relationships": {
            "calendar_date": {
                "data": {
                    "id": 1,
                    "type": "calendar_date"
                }
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "calendar_date_status_history",
        "id": 1,
        "attributes": {
            "created_at": "2016-03-14T00:00:00+00:00",
            "updated_at": "2016-03-14T00:00:00+00:00",
            "deleted_at": null,
            "id": 1,
            "from": "2016-03-14T00:00:00+00:00",
            "status": "open",
            "calendar_id": null
        },
        "relationships": {
            "calendar_date": {
                "data": {
                    "type": "calendar_date",
                    "id": 1
                },
                "links": {
                    "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates-status-history",
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates\/1"
                }
            },
            "calendar_dates_status_history": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_dates\/1\/calendar_dates_status_history"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_date_status_history\/1"
        }
    },
    "links": []
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ],
        "data.attributes.status": [
            "The data.attributes.status field is required."
        ],
        "data.relationships.calendar_date.data.type": [
            "The data.relationships.calendar date.data.type field is required."
        ],
        "data.relationships.calendar_date.data.id": [
            "The data.relationships.calendar date.data.id field is required."
        ]
    }
}

HTTP Request

POST api/v1/calendar-dates-status-history

Body Parameters

Parameter Type Status Description
data.type string required Type must be calendar_date_status_history.
data.attributes.from date optional field is required.
data.attributes.status string optional optional must be one of the followingopen, blocked.
data.relationships.calendar_date.data.id integer required Id of CalendarDate.
data.relationships.calendar_date.data.type string required Must be calendar_date.

PATCH CalendarDateHistory


Requires authentication updates a specific calendar date history

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates-status-history/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":"1","type":"calendar_date_status_history","attributes":{"from":"2019-06-06T00:00:00+00:00","status":"open"},"relationships":{"calendar_date":{"data":{"id":1,"type":"calendar_date"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates-status-history/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": "1",
        "type": "calendar_date_status_history",
        "attributes": {
            "from": "2019-06-06T00:00:00+00:00",
            "status": "open"
        },
        "relationships": {
            "calendar_date": {
                "data": {
                    "id": 1,
                    "type": "calendar_date"
                }
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "calendar_date_status_history",
        "id": 1,
        "attributes": {
            "created_at": "2016-03-14T00:00:00+00:00",
            "updated_at": "2016-03-14T00:00:00+00:00",
            "deleted_at": null,
            "id": 1,
            "from": "2016-03-14T00:00:00+00:00",
            "status": "open",
            "calendar_id": null
        },
        "relationships": {
            "calendar_date": {
                "data": {
                    "type": "calendar_date",
                    "id": 1
                },
                "links": {
                    "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates-status-history",
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates\/1"
                }
            },
            "calendar_dates_status_history": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_dates\/1\/calendar_dates_status_history"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_date_status_history\/1"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The data.id field is required."
        ],
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ],
        "data.attributes.status": [
            "The data.attributes.status field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/calendar-dates-status-history/{calendarDateHistory}

Body Parameters

Parameter Type Status Description
data.id string required id must be a valid CalendarDateHistory id.
data.type string required Type must be calendar_date_status_history.
data.attributes.from field optional is required.
data.attributes.status string optional optional must be one of the followingopen, blocked.
data.relationships.calendar_date.data.id integer required Id of CalendarDate.
data.relationships.calendar_date.data.type string required Must be calendar_date.

GET CalendarDateHistory


Requires authentication returns a specific calendar date history

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates-status-history/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates-status-history/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "calendar_date_status_history",
        "id": 1,
        "attributes": {
            "created_at": "2016-03-14T00:00:00+00:00",
            "updated_at": "2016-03-14T00:00:00+00:00",
            "deleted_at": null,
            "id": 1,
            "from": "2016-03-14T00:00:00+00:00",
            "status": "open",
            "calendar_id": null
        },
        "relationships": {
            "calendar_date": {
                "data": {
                    "type": "calendar_date",
                    "id": 1
                },
                "links": {
                    "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates-status-history",
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates\/1"
                }
            },
            "calendar_dates_status_history": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_dates\/1\/calendar_dates_status_history"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_date_status_history\/1"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/calendar-dates-status-history/{history}

CalendarDate Requests

API calls for managing Calendar dates

GET Calendar Dates


Requires authentication returns all calendar dates

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 5,
            "total": 5,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "calendar-date",
            "id": 118,
            "attributes": {
                "created_at": "2019-07-09T14:59:54+00:00",
                "updated_at": "2019-07-09T14:59:54+00:00",
                "deleted_at": null,
                "id": 118,
                "calendar_id": 204,
                "date": "2016-03-14",
                "status": "open"
            },
            "relationships": {
                "calendar": {
                    "data": {
                        "type": "calendar",
                        "id": 204
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_dates\/118\/calendars"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates\/118"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates?page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/calendar-dates

Query Parameters

Parameter Status Description
filter[id] optional search for specific id or ids.
filter[calendar] optional filter on specific calendar id.
filter[date] optional search for specific date.
filter[status] optional search for status.

GET Calendar Date


Requires authentication returns a specific Calendar Date

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "calendar-date",
            "id": 118,
            "attributes": {
                "created_at": "2019-07-09T14:59:54+00:00",
                "updated_at": "2019-07-09T14:59:54+00:00",
                "deleted_at": null,
                "id": 118,
                "calendar_id": 204,
                "date": "2016-03-14",
                "status": "open"
            },
            "relationships": {
                "calendar": {
                    "data": {
                        "type": "calendar",
                        "id": 204
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_dates\/118\/calendars"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates\/118"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates?page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/calendar-dates/{calendar}

POST Calendar Date


Requires authentication creates a new Calendar Date

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"attributes":{"date":"2019-01-10"},"relationships":{"calendar":{"data":{"type":"calendar","id":"1"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "attributes": {
            "date": "2019-01-10"
        },
        "relationships": {
            "calendar": {
                "data": {
                    "type": "calendar",
                    "id": "1"
                }
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "calendar-date",
            "id": 118,
            "attributes": {
                "created_at": "2019-07-09T14:59:54+00:00",
                "updated_at": "2019-07-09T14:59:54+00:00",
                "deleted_at": null,
                "id": 118,
                "calendar_id": 204,
                "date": "2016-03-14",
                "status": "open"
            },
            "relationships": {
                "calendar": {
                    "data": {
                        "type": "calendar",
                        "id": 204
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_dates\/118\/calendars"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates\/118"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates?page[number]=1"
    }
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.date": [
            "The data.attributes.date field is required."
        ],
        "data.relationships.calendar.data.type": [
            "The data.relationships.calendar.data.type field is required."
        ],
        "data.relationships.calendar.data.id": [
            "The data.relationships.calendar.data.id field is required."
        ]
    }
}

HTTP Request

POST api/v1/calendar-dates

Body Parameters

Parameter Type Status Description
data.attributes.date string required must be a valid date.
data.relationships.calendar.data.type string required One of the categories mentioned at the top of this page.
data.relationships.calendar.data.id id required a correct calendar id.

POST Calendar Date


Requires authentication updates a Calendar Date

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendar-dates/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "PATCH",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "calendar-date",
            "id": 118,
            "attributes": {
                "created_at": "2019-07-09T14:59:54+00:00",
                "updated_at": "2019-07-09T14:59:54+00:00",
                "deleted_at": null,
                "id": 118,
                "calendar_id": 204,
                "date": "2016-03-14",
                "status": "open"
            },
            "relationships": {
                "calendar": {
                    "data": {
                        "type": "calendar",
                        "id": 204
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendar_dates\/118\/calendars"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates\/118"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/calendar-dates?page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

PATCH api/v1/calendar-dates/{calendarDate}

Contracts

API calls for managing and retrieving resources related to the Contract entity.

GET Contracts


Requires authentication Endpoint to return all the applicable Contract records.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/contracts? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/contracts");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": [
        {
            "type": "contract",
            "id": "21",
            "attributes": {
                "category": "collection_route_calendar",
                "from": "2020-06-18",
                "until": "2020-06-19",
                "properties": {
                    "every_x_weeks": 1
                },
                "repeat": null
            }
        },
        {
            "type": "contract",
            "id": "22",
            "attributes": {
                "category": "collection_sub_route_calendar",
                "from": "2020-06-22",
                "until": "2020-06-19",
                "properties": {
                    "day_of_the_week": 1,
                    "outside_zone": true,
                    "time_limitations": [
                        {
                            "category": "before",
                            "hour": "07:30"
                        }
                    ]
                },
                "repeat": null
            }
        },
        {
            "type": "contract",
            "id": "23",
            "attributes": {
                "category": "collection_seasonal_route_calendar",
                "from": "2020-06-22",
                "until": "2020-06-29",
                "properties": {
                    "every_x_weeks": 1
                },
                "repeat": "yearly"
            }
        },
        {
            "type": "contract",
            "id": "24",
            "attributes": {
                "category": "collection_seasonal_sub_route_calendar",
                "from": "2020-06-22",
                "until": "2020-06-29",
                "properties": {
                    "day_of_the_week": 1,
                    "time_limitations": [],
                    "outside_zone": false
                },
                "repeat": null
            }
        },
        {
            "type": "contract",
            "id": "25",
            "attributes": {
                "category": "collection_seasonal_route_calendar",
                "from": "2020-06-22",
                "until": "2020-06-29",
                "properties": {
                    "every_x_weeks": 1
                },
                "repeat": "yearly"
            }
        },
        {
            "type": "contract",
            "id": "26",
            "attributes": {
                "category": "collection_seasonal_sub_route_calendar",
                "from": "2020-06-23",
                "until": "2020-06-29",
                "properties": {
                    "day_of_the_week": 2,
                    "time_limitations": [],
                    "outside_zone": true
                },
                "repeat": null
            }
        },
        {
            "type": "contract",
            "id": "28",
            "attributes": {
                "category": "collection_sub_route_calendar",
                "from": "2020-06-23",
                "until": null,
                "properties": {
                    "day_of_the_week": 2,
                    "outside_zone": true,
                    "time_limitations": [
                        {
                            "category": "between",
                            "until": "17:00",
                            "from": "07:30"
                        }
                    ]
                },
                "repeat": null
            }
        },
        {
            "type": "contract",
            "id": "29",
            "attributes": {
                "category": "collection_sub_route_calendar",
                "from": "2020-06-25",
                "until": null,
                "properties": {
                    "day_of_the_week": 4,
                    "time_limitations": [
                        {
                            "category": "after",
                            "hour": "23:00"
                        }
                    ]
                },
                "repeat": null
            }
        },
        {
            "type": "contract",
            "id": "30",
            "attributes": {
                "category": "collection_stop_calendar",
                "from": "2020-06-18",
                "until": "2020-06-19",
                "properties": {
                    "remarks": "Maandelijkse stop"
                },
                "repeat": "monthly"
            }
        }
    ],
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 9,
            "total": 9,
            "last_page": 1
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/contracts?page=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/contracts?page=1",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/contracts?page=1"
    }
}

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (405):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 405,
        "source": null,
        "title": "Method Not Allowed",
        "detail": "The GET method is not supported for this route."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "filter.calendar": [
            "The selected filter.calendar is invalid."
        ],
        "filter.person": [
            "The selected filter.person is invalid."
        ]
    }
}

HTTP Request

GET api/v1/contracts

Query Parameters

Parameter Status Description
filter[calendar] optional Filter Contract with given calendar.
filter[person] optional Filter Contract with given person.
filter[category] optional Filter Contract with specific category.

POST Contract


Requires authentication Endpoint to create a new Contract record.

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/contracts" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"attributes":{"category":"collection_route_category","properties":"[]","from":"2019-09-09","until":"2019-10-09"},"relationships":{"calendar":{"id":1,"type":"omnis"},"person":{"id":1,"type":"debitis"},"option":{"id":1,"type":"aut"}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/contracts");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "attributes": {
            "category": "collection_route_category",
            "properties": "[]",
            "from": "2019-09-09",
            "until": "2019-10-09"
        },
        "relationships": {
            "calendar": {
                "id": 1,
                "type": "omnis"
            },
            "person": {
                "id": 1,
                "type": "debitis"
            },
            "option": {
                "id": 1,
                "type": "aut"
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "data": {
        "type": "contract",
        "id": "49",
        "attributes": {
            "category": "collection_route_calendar",
            "from": "2020-09-12",
            "until": "2020-09-18",
            "properties": [],
            "repeat": null
        }
    }
}

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ]
    }
}

HTTP Request

POST api/v1/contracts

Body Parameters

Parameter Type Status Description
data.attributes.category string required Should match a value from \App\Models\Enums\ContractCategory.
data.attributes.properties array optional optional The properties for the Contract.
data.attributes.from date optional optional The from date.
data.attributes.until date optional optional The until date.
data.relationships.calendar.id integer required The ID of the parent calendar.
data.relationships.calendar.type string optional required. Should match 'calendar'.
data.relationships.person.id integer required The ID of the person.
data.relationships.person.type string required Should match 'person'.
data.relationships.option.id integer required The ID of the option.
data.relationships.option.type string required Should match 'option'.

GET Single Contract


Requires authentication Endpoint to retrieve a single Contract resource.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/contracts/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/contracts/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "contract",
        "id": "55",
        "attributes": {
            "category": "collection_route_calendar",
            "from": null,
            "until": null,
            "properties": [],
            "repeat": null
        }
    }
}

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/contracts/{contract}

PATCH Contract


Requires authentication Endpoint to update an existing Contract record.

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/contracts/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":2,"attributes":{"category":"collection_route_category","properties":"[]","from":"2019-10-11","until":"2019-10-11"},"relationships":{"calendar":{"id":1,"type":"debitis"},"person":{"id":1,"type":"dolore"},"option":{"id":1,"type":"sit"}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/contracts/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": 2,
        "attributes": {
            "category": "collection_route_category",
            "properties": "[]",
            "from": "2019-10-11",
            "until": "2019-10-11"
        },
        "relationships": {
            "calendar": {
                "id": 1,
                "type": "debitis"
            },
            "person": {
                "id": 1,
                "type": "dolore"
            },
            "option": {
                "id": 1,
                "type": "sit"
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

[]

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The data.id field is required.",
            "The selected data.id is invalid.",
            "id mismatch, data.id value is not the same as in the link."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required.",
            "The selected data.attributes.category is invalid."
        ],
        "data.attributes.properties": [
            "The data.attributes.properties must be an array."
        ],
        "data.attributes.from": [
            "The data.attributes.from is not a valid date."
        ],
        "data.attributes.until": [
            "The data.attributes.until is not a valid date."
        ],
        "data.relationships.calendar": [
            "The data.relationships.calendar field is required."
        ],
        "data.relationships.calendar.data.id": [
            "The data.relationships.calendar.data.id field is required.",
            "The selected data.relationships.calendar.data.id is invalid."
        ],
        "data.relationships.calendar.data.type": [
            "The data.relationships.calendar.data.type field is required.",
            "The data.relationships.calendar.data.type value does not match required value."
        ],
        "data.relationships.person": [
            "The data.relationships.person field is required."
        ],
        "data.relationships.person.data.id": [
            "The data.relationships.person.data.id field is required.",
            "The selected data.relationships.person.data.id is invalid."
        ],
        "data.relationships.person.data.type": [
            "The data.relationships.person.data.type field is required.",
            "The data.relationships.person.data.type value does not match required value."
        ]
    }
}

HTTP Request

PATCH api/v1/contracts/{contract}

Body Parameters

Parameter Type Status Description
data.id integer required The id must match the id in the URL.
data.attributes.category string required One of the categories allowed in \App\Models\Enum\ContractCategory.
data.attributes.properties array optional optional Properties of this Contract:
data.attributes.from date optional optional From date.
data.attributes.until date optional optional Until date.
data.relationships.calendar.id integer optional optional The ID of the parent calendar.
data.relationships.calendar.type string optional optional. Should match 'calendar'.
data.relationships.person.id integer optional optional The ID of the person.
data.relationships.person.type string optional optional Should match 'person'.
data.relationships.option.id integer optional optional The ID of the option.
data.relationships.option.type string optional optional Should match 'option'.

DELETE Contract


Requires authentication Endpoint to delete a specific Contract.

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/contracts/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/contracts/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v1/contracts/{contract}

GET Contract sub-routes

Endpoint to retrieve all the sub-routes for a given Contract.


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/contracts/1/relationships/sub-routes" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/contracts/1/relationships/sub-routes");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": [
        {
            "type": "contract",
            "id": "310",
            "attributes": {
                "category": "collection_sub_route_calendar",
                "from": null,
                "until": null,
                "properties": [],
                "repeat": null
            }
        },
        {
            "type": "contract",
            "id": "311",
            "attributes": {
                "category": "collection_sub_route_calendar",
                "from": null,
                "until": null,
                "properties": [],
                "repeat": null
            }
        }
    ],
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 2,
            "total": 2,
            "last_page": 1
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/contracts\/309\/relationships\/sub-routes?page=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/contracts\/309\/relationships\/sub-routes?page=1",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/contracts\/309\/relationships\/sub-routes?page=1"
    }
}

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/contracts/{contract}/relationships/sub-routes

Customer

API Calls for managing the Customer entity.

Class CustomerProfilesController

api/v1/customers/{customer}/profiles

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/customers/{customer}/profiles

GET Calenders


Requires authentication Endpoint to fetch Calendar entities related to a specific customer.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/customers/1/calendars" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/customers/1/calendars");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

HTTP Request

GET api/v2/customers/{customer}/calendars

Customer Requests

API calls for managing Customers

GET customers


Requires authentication returns all customers

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/customers? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 5,
            "total": 5,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "customer",
            "id": 1,
            "attributes": {
                "created_at": "2014-02-07T09:58:44+00:00",
                "updated_at": "2014-09-16T15:29:33+00:00",
                "deleted_at": null,
                "name": "DEFAULT",
                "key_code": "default",
                "active": 1,
                "link_id": 1,
                "description": "gebruiken voor koppeling van acties",
                "category": "project_customer"
            },
            "relationships": {
                "geo-locations": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/1\/geo-locations"
                    }
                },
                "modules": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/1\/modules"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/customers?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/customers?page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/customers

Query Parameters

Parameter Status Description
filter[id] optional search for specific id or ids.
filter[category] optional filter on specific category.
filter[link_id] optional search for specific link id or link ids.
filter[name] optional search for specific name.
filter[key_code] optional search for specific key code.
filter[active] optional filter on active or inactive customers. 1 or 0.

GET specific customer


Requires authentication returns a specific customer

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "customer",
        "id": 1,
        "attributes": {
            "created_at": "2014-02-07T09:58:44+00:00",
            "updated_at": "2014-09-16T15:29:33+00:00",
            "deleted_at": null,
            "name": "DEFAULT",
            "key_code": "default",
            "active": 1,
            "link_id": 1,
            "description": "gebruiken voor koppeling van acties",
            "category": "project_customer"
        },
        "relationships": {
            "geo-locations": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/1\/geo-locations"
                }
            },
            "modules": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/1\/modules"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/1"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/customers/{customer}

GET Customer configuration


Requires authentication Get the specific configuration settings for a specific customer.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/configuration" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/configuration");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "example-key": [
                "example-value-1",
                "example-value-2"
            ]
        }
    ],
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "customer": [
            "The selected customer is invalid."
        ]
    }
}

HTTP Request

GET api/v1/customers/{customer}/configuration

POST options


Requires authentication Attaches 1 or multiple Options to the GeoLocations of a specific Customer.

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/options" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/options");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 698,
            "last_page": 7
        },
        "warnings": []
    },
    "data": [
        {
            "type": "option",
            "id": 1,
            "attributes": {
                "created_at": "2012-09-25T17:48:14+00:00",
                "updated_at": "2016-03-03T09:17:50+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "other_garbage_event_origin",
                "name": "Burger"
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options?page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

POST api/v1/customers/{customer}/options

DELETE Options


Requires authentication Detaches 1 or multiple Options from the GeoLocations of a specific Customer.

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/options" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/options");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 698,
            "last_page": 7
        },
        "warnings": []
    },
    "data": [
        {
            "type": "option",
            "id": 1,
            "attributes": {
                "created_at": "2012-09-25T17:48:14+00:00",
                "updated_at": "2016-03-03T09:17:50+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "other_garbage_event_origin",
                "name": "Burger"
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options?page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v1/customers/{customer}/options

Customer Validator controllers

API Calls for managing the relation between customer and attached validators.

Class CustomerValidatorsController

GET Validators by customer

Endpoint to retrieve all the validators for a given customer.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/validators" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/validators");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 3,
            "total": 3,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "validator",
            "id": 244,
            "attributes": {
                "created_at": "2020-02-24T10:40:39+00:00",
                "updated_at": "2020-02-24T10:40:39+00:00",
                "deleted_at": null,
                "entity_type": "product",
                "field": "chip_code",
                "validation_rules": [
                    "required"
                ],
                "priority": 0
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 524
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/244\/customers"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/244"
            }
        },
        {
            "type": "validator",
            "id": 245,
            "attributes": {
                "created_at": "2020-02-24T10:40:39+00:00",
                "updated_at": "2020-02-24T10:40:39+00:00",
                "deleted_at": null,
                "entity_type": "product",
                "field": "chip_code",
                "validation_rules": [
                    "required"
                ],
                "priority": 0
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 525
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/245\/customers"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/245"
            }
        },
        {
            "type": "validator",
            "id": 246,
            "attributes": {
                "created_at": "2020-02-24T10:40:39+00:00",
                "updated_at": "2020-02-24T10:40:39+00:00",
                "deleted_at": null,
                "entity_type": "product",
                "field": "chip_code",
                "validation_rules": [
                    "required"
                ],
                "priority": 0
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 526
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/246\/customers"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/246"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/validators",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/validators?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/validators?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/customers/{customer}/validators

Event Requests

API calls for managing Events

Available categories:

Name Description
action_event
ciaccess_complaint_event
ciaccess_info_request_event
collective_complaint_event
collective_info_request_event
complaint_event
info_request_event
other_garbage_event

GET Events from Product


Requires authentication returns events linked to a specific product

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/products/1/events? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/products/1/events");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "event",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-08T19:15:26+00:00",
                "updated_at": "2016-03-10T12:24:38+00:00",
                "deleted_at": null,
                "tags": [],
                "category": "ciaccess_complaint_event",
                "memo": null,
                "status": null,
                "intervention_date": null,
                "process_memo": "lag afval naast, is meegenomen",
                "collection_date": null,
                "collection_time": null,
                "chipcode": null,
                "barcode": null,
                "labelcode": null,
                "properties": []
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/customers"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 4
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/pois"
                    }
                },
                "product": {
                    "data": {
                        "type": "product",
                        "id": 14
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/product"
                    }
                },
                "origin": {
                    "data": {
                        "type": null,
                        "id": 15
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/origins"
                    }
                },
                "source": {
                    "data": {
                        "type": null,
                        "id": 20
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/sources"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/events",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/events?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/events?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/products/{product}/events

Query Parameters

Parameter Status Description
filter[id] optional Search for specific Event id or ids.
filter[category] optional Filter specific Event category (categories mentioned at the top of this page).

EventStatusHistory Requests

API calls for managing Event Status Histories

Available statuses:

Name Description
active
auto_blocked
blocked
cancelled
inactive
in_progress
open
planned
processed
processed_invalid
processed_valid

GET Event Status Histories


Requires authentication returns event status histories

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/event-status-history? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/event-status-history");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "event-status-history",
            "id": 1,
            "attributes": {
                "created_at": "2019-01-01T10:00:00+00:00",
                "updated_at": "2019-01-01T10:00:00+00:00",
                "deleted_at": null,
                "status": "open",
                "from": "2019-01-01T10:00:00+00:00"
            },
            "relationships": {
                "event": {
                    "data": {
                        "type": "event",
                        "id": 576
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/event\/1\/event"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/event-status-history\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/event-status-history?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/event-status-history?size=1&page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/event-status-history?size=1&page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (401):

{
    "message": "Unauthenticated."
}

HTTP Request

GET api/v1/event-status-history

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[from] optional event status histories from a certain date.
filter[status] optional Find event status history with a specific status.
filter[from_min] optional event status histories from a certain date until now.
filter[from_max] optional event status histories until the given date.
filter[on_date] optional The event status history that is active on the given date.
filter[event] optional Find the event status history with a specific event.

POST Event Status History


Requires authentication

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/event-status-history" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"event-status-history","attributes":{"event_id":1,"status":"open","from":"2019-05-10T00:00:00+00:00"}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/event-status-history");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "event-status-history",
        "attributes": {
            "event_id": 1,
            "status": "open",
            "from": "2019-05-10T00:00:00+00:00"
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "event-status-history",
        "id": 1,
        "attributes": {
            "created_at": "2019-01-01T10:00:00+00:00",
            "updated_at": "2019-01-01T10:00:00+00:00",
            "deleted_at": null,
            "status": "open",
            "from": "2019-01-01T10:00:00+00:00"
        },
        "relationships": {
            "event": {
                "data": {
                    "type": "event",
                    "id": 578
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/event\/8\/event"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/event-status-history\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes": [
            "No attributes added to the request."
        ],
        "data.attributes.status": [
            "The data.attributes.status field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from date field is required."
        ]
    }
}

HTTP Request

POST api/v1/event-status-history

Body Parameters

Parameter Type Status Description
data.type string required Type must be event-status-history.
data.attributes.event_id integer optional optional Event id.
data.attributes.status string required One of the status mentioned at the top of this page.
data.attributes.from date required From date.

GET Event Status History


Requires authentication returns a specific event status history

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/event-status-history/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/event-status-history/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "event-status-history",
        "id": 1,
        "attributes": {
            "created_at": "2019-01-01T10:00:00+00:00",
            "updated_at": "2019-01-01T10:00:00+00:00",
            "deleted_at": null,
            "status": "open",
            "from": "2019-01-01T10:00:00+00:00"
        },
        "relationships": {
            "event": {
                "data": {
                    "type": "event",
                    "id": 578
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/event\/8\/event"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/event-status-history\/1"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (401):

{
    "message": "Unauthenticated."
}

HTTP Request

GET api/v1/event-status-history/{eventStatusHistory}

PATCH Event Status History


Requires authentication

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/event-status-history/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":"1","type":"event-status-history","attributes":{"event_id":1,"status":"open","from":"2019-05-10T00:00:00+00:00"}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/event-status-history/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": "1",
        "type": "event-status-history",
        "attributes": {
            "event_id": 1,
            "status": "open",
            "from": "2019-05-10T00:00:00+00:00"
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "event-status-history",
        "id": 1,
        "attributes": {
            "created_at": "2019-01-01T10:00:00+00:00",
            "updated_at": "2019-01-01T10:00:00+00:00",
            "deleted_at": null,
            "status": "open",
            "from": "2019-01-01T10:00:00+00:00"
        },
        "relationships": {
            "event": {
                "data": {
                    "type": "event",
                    "id": 578
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/event\/8\/event"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/event-status-history\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The data.id field is required."
        ],
        "data.attributes": [
            "No attributes added to the request."
        ],
        "data.attributes.status": [
            "The data.attributes.status field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from date field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/event-status-history/{eventStatusHistory}

Body Parameters

Parameter Type Status Description
data.id id required must be a valid EventStatusHistory id.
data.type string required Type must be event-status-history.
data.attributes.event_id integer optional optional Event id.
data.attributes.status string required One of the status mentioned at the top of this page.
data.attributes.from date required From date.

Events

API calls for managing Events

Available categories:

Name Description
action_event
ciaccess_complaint_event
ciaccess_info_request_event
collective_complaint_event
collective_info_request_event
complaint_event
info_request_event
other_garbage_event

GET Events


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/events? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/events");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "event",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-08T19:15:26+00:00",
                "updated_at": "2016-03-10T12:24:38+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "ciaccess_complaint_event",
                "memo": null,
                "status": null,
                "intervention_date": null,
                "process_memo": "lag afval naast, is meegenomen",
                "collection_date": null,
                "collection_time": null,
                "chipcode": null,
                "barcode": null,
                "labelcode": null,
                "properties": [],
                "weight": null
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/customers"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 4
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/pois"
                    }
                },
                "product": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/product"
                    }
                },
                "deliver_product": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/deliver-product"
                    }
                },
                "origin": {
                    "data": {
                        "type": "option",
                        "id": 15
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/origins"
                    }
                },
                "source": {
                    "data": {
                        "type": "option",
                        "id": 20
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/sources"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=7"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/events

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Which kind of Event.
filter[link_id] optional Find Events with the given legacy id.
filter[poi_id] optional Events attached to a certain poi.
filter[product_id] optional Events attached to a certain product.

POST Event


Requires authentication

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/events" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"events","attributes":{"category":"ciaccess_complaint_event","status":"'open', 'cancelled'","telephone_number":"03 200 47 58 75","email":"test@inovim.eu","external_id":"1","tags":"garbage, external","memo":"This is a Memo","process_memo":"ExampleMemo","emailed_at":2019,"emailed_by":0},"relationships":{"poi":{"data":{"id":1}},"profile":{"data":{"id":1}},"source":{"data":{"id":1}},"origin":{"data":{"id":1}},"product":{"data":{"id":1}},"product_profile":{"data":{"id":1}},"team":{"data":{"id":1}},"reason":{"data":{"id":1}},"subject":{"data":{"id":1}},"description":{"data":{"id":1}},"location":{"data":{"id":1}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/events");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "events",
        "attributes": {
            "category": "ciaccess_complaint_event",
            "status": "'open', 'cancelled'",
            "telephone_number": "03 200 47 58 75",
            "email": "test@inovim.eu",
            "external_id": "1",
            "tags": "garbage, external",
            "memo": "This is a Memo",
            "process_memo": "ExampleMemo",
            "emailed_at": 2019,
            "emailed_by": 0
        },
        "relationships": {
            "poi": {
                "data": {
                    "id": 1
                }
            },
            "profile": {
                "data": {
                    "id": 1
                }
            },
            "source": {
                "data": {
                    "id": 1
                }
            },
            "origin": {
                "data": {
                    "id": 1
                }
            },
            "product": {
                "data": {
                    "id": 1
                }
            },
            "product_profile": {
                "data": {
                    "id": 1
                }
            },
            "team": {
                "data": {
                    "id": 1
                }
            },
            "reason": {
                "data": {
                    "id": 1
                }
            },
            "subject": {
                "data": {
                    "id": 1
                }
            },
            "description": {
                "data": {
                    "id": 1
                }
            },
            "location": {
                "data": {
                    "id": 1
                }
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "event",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-08T19:15:26+00:00",
                "updated_at": "2016-03-10T12:24:38+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "ciaccess_complaint_event",
                "memo": null,
                "status": null,
                "intervention_date": null,
                "process_memo": "lag afval naast, is meegenomen",
                "collection_date": null,
                "collection_time": null,
                "chipcode": null,
                "barcode": null,
                "labelcode": null,
                "properties": [],
                "weight": null
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/customers"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 4
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/pois"
                    }
                },
                "product": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/product"
                    }
                },
                "origin": {
                    "data": {
                        "type": "option",
                        "id": 15
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/origins"
                    }
                },
                "source": {
                    "data": {
                        "type": "option",
                        "id": 20
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/sources"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=7"
    }
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The selected data.type is invalid."
        ],
        "data.attributes.category": [
            "The selected data.attributes.category is invalid."
        ],
        "data.relationships.poi.data.id": [
            "The data.relationships.poi.data.id field is required."
        ]
    }
}

HTTP Request

POST api/v1/events

Body Parameters

Parameter Type Status Description
data.type string required Type must be events.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.status string optional optional A status describing what state the Event is in.
data.attributes.telephone_number string optional optional A telephone number to contact the reporter.
data.attributes.email string optional optional An email to contact the reporter.
data.attributes.external_id string optional optional Used to include the legacy Event.
data.attributes.tags string optional optional Tags used to filter the events.
data.attributes.memo string optional optional Add a memo to describe what needs to be done.
data.relationships.poi.data.id integer required
data.relationships.profile.data.id integer required
data.relationships.source.data.id integer optional optional required for <action_event, other_garbage_event, complaint_event>
data.relationships.origin.data.id integer optional optional required for <action_event, other_garbage_event, complaint_event>
data.relationships.product.data.id integer optional optional required for
data.relationships.product_profile.data.id integer optional optional required for
data.relationships.team.data.id integer optional optional required for
data.relationships.reason.data.id integer optional optional required for
data.attributes.process_memo string optional optional required for
data.attributes.emailed_at integer optional DateTime required for
data.attributes.emailed_by integer optional string required for
data.relationships.subject.data.id integer optional optional required for
data.relationships.description.data.id integer optional optional required for
data.relationships.location.data.id integer optional optional required for

PATCH Event


Requires authentication

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/events/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"events","attributes":{"category":"ciaccess_complaint_event","status":"'open', 'cancelled'","telephone_number":"03 200 47 58 75","email":"test@inovim.eu","external_id":"1","tags":"garbage, external","memo":"This is a Memo","process_memo":"ExampleMemo","emailed_at":2019,"emailed_by":0},"relationships":{"poi":{"data":{"id":1}},"profile":{"data":{"id":1}},"source":{"data":{"id":1}},"origin":{"data":{"id":1}},"product":{"data":{"id":1}},"product_profile":{"data":{"id":1}},"team":{"data":{"id":1}},"reason":{"data":{"id":1}},"subject":{"data":{"id":1}},"description":{"data":{"id":1}},"location":{"data":{"id":1}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/events/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "events",
        "attributes": {
            "category": "ciaccess_complaint_event",
            "status": "'open', 'cancelled'",
            "telephone_number": "03 200 47 58 75",
            "email": "test@inovim.eu",
            "external_id": "1",
            "tags": "garbage, external",
            "memo": "This is a Memo",
            "process_memo": "ExampleMemo",
            "emailed_at": 2019,
            "emailed_by": 0
        },
        "relationships": {
            "poi": {
                "data": {
                    "id": 1
                }
            },
            "profile": {
                "data": {
                    "id": 1
                }
            },
            "source": {
                "data": {
                    "id": 1
                }
            },
            "origin": {
                "data": {
                    "id": 1
                }
            },
            "product": {
                "data": {
                    "id": 1
                }
            },
            "product_profile": {
                "data": {
                    "id": 1
                }
            },
            "team": {
                "data": {
                    "id": 1
                }
            },
            "reason": {
                "data": {
                    "id": 1
                }
            },
            "subject": {
                "data": {
                    "id": 1
                }
            },
            "description": {
                "data": {
                    "id": 1
                }
            },
            "location": {
                "data": {
                    "id": 1
                }
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "event",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-08T19:15:26+00:00",
                "updated_at": "2016-03-10T12:24:38+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "ciaccess_complaint_event",
                "memo": null,
                "status": null,
                "intervention_date": null,
                "process_memo": "lag afval naast, is meegenomen",
                "collection_date": null,
                "collection_time": null,
                "chipcode": null,
                "barcode": null,
                "labelcode": null,
                "properties": [],
                "weight": null
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/customers"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 4
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/pois"
                    }
                },
                "product": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/product"
                    }
                },
                "origin": {
                    "data": {
                        "type": "option",
                        "id": 15
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/origins"
                    }
                },
                "source": {
                    "data": {
                        "type": "option",
                        "id": 20
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/sources"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=7"
    }
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The selected data.type is invalid."
        ],
        "data.attributes.category": [
            "The selected data.attributes.category is invalid."
        ],
        "data.relationships.poi.data.id": [
            "The data.relationships.poi.data.id field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/events/{event}

Body Parameters

Parameter Type Status Description
data.type string required Type must be events.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.status string optional optional A status describing what state the Event is in.
data.attributes.telephone_number string optional optional A telephone number to contact the reporter.
data.attributes.email string optional optional An email to contact the reporter.
data.attributes.external_id string optional optional Used to include the legacy Event.
data.attributes.tags string optional optional Tags used to filter the events.
data.attributes.memo string optional optional Add a memo to describe what needs to be done.
data.relationships.poi.data.id integer required
data.relationships.profile.data.id integer required
data.relationships.source.data.id integer optional optional required for <action_event, other_garbage_event, complaint_event>
data.relationships.origin.data.id integer optional optional required for <action_event, other_garbage_event, complaint_event>
data.relationships.product.data.id integer optional optional required for
data.relationships.product_profile.data.id integer optional optional required for
data.relationships.team.data.id integer optional optional required for
data.relationships.reason.data.id integer optional optional required for
data.attributes.process_memo string optional optional required for
data.attributes.emailed_at integer optional DateTime required for
data.attributes.emailed_by integer optional string required for
data.relationships.subject.data.id integer optional optional required for
data.relationships.description.data.id integer optional optional required for
data.relationships.location.data.id integer optional optional required for

GET Event


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/events/1? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/events/1");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "event",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-08T19:15:26+00:00",
                "updated_at": "2016-03-10T12:24:38+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "ciaccess_complaint_event",
                "memo": null,
                "status": null,
                "intervention_date": null,
                "process_memo": "lag afval naast, is meegenomen",
                "collection_date": null,
                "collection_time": null,
                "chipcode": null,
                "barcode": null,
                "labelcode": null,
                "properties": [],
                "weight": null
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/customers"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 4
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/pois"
                    }
                },
                "product": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/product"
                    }
                },
                "deliver_product": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/deliver_product"
                    }
                },
                "origin": {
                    "data": {
                        "type": "option",
                        "id": 15
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/origins"
                    }
                },
                "source": {
                    "data": {
                        "type": "option",
                        "id": 20
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/sources"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=7"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/events/{event}

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Which kind of Event.
filter[link_id] optional Find Events with the given legacy id.
filter[poi_id] optional Events attached to a certain poi.
filter[product_id] optional Events attached to a certain product.

GET Events from a specific Poi


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/events? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/events");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "event",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-08T19:15:26+00:00",
                "updated_at": "2016-03-10T12:24:38+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "ciaccess_complaint_event",
                "memo": null,
                "status": null,
                "intervention_date": null,
                "process_memo": "lag afval naast, is meegenomen",
                "collection_date": null,
                "collection_time": null,
                "chipcode": null,
                "barcode": null,
                "labelcode": null,
                "properties": [],
                "weight": null
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/customers"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 4
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/pois"
                    }
                },
                "product": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/product"
                    }
                },
                "origin": {
                    "data": {
                        "type": "option",
                        "id": 15
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/origins"
                    }
                },
                "source": {
                    "data": {
                        "type": "option",
                        "id": 20
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1\/sources"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/events\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/events?size=1&page[number]=7"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/pois/{poi}/events

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Which kind of Event.
filter[link_id] optional Find Events with the given legacy id.
filter[poi_id] optional Events attached to a certain poi.
filter[product_id] optional Events attached to a certain product.

GeoLocation Requests

API calls for managing GeoLocations

Available categories:

Name Description
country_geo_location
city_geo_location
street_geo_location

GET GeoLocations from Customer


Requires authentication Returns all geoLocations from a specific customer

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/geo-locations? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/geo-locations");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 389,
            "last_page": 4
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "geo-location",
            "id": 9,
            "attributes": {
                "created_at": "2016-03-15T10:37:05+00:00",
                "updated_at": "2017-10-24T10:48:44+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "city_geo_location",
                "name": "TEST 1",
                "external_id": "1",
                "code": ""
            },
            "relationships": {
                "parent": {
                    "data": {
                        "type": "geo-location",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/9\/parent"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/9"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/geo-locations",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/geo-locations?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/geo-locations?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/geo-locations?page[number]=4"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/customers/{customer}/geo-locations

Query Parameters

Parameter Status Description
filter[category] optional Filter specific GeoLocation category.
filter[name] optional Find GeoLocation with given name.
filter[code] optional Filter on specific GeoLocation code.
filter[parent_id] optional Filter on specific GeoLocation parent_id.
filter[link_id] optional Filter on specific GeoLocation link_id.

GET GeoLocations


Requires authentication returns all geo-locations

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 391,
            "last_page": 4
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "geo-location",
            "id": 3,
            "attributes": {
                "created_at": "2015-12-23T14:22:23+00:00",
                "updated_at": "2015-12-23T14:22:23+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "city_geo_location",
                "name": "DEFAULT",
                "external_id": null,
                "code": null
            },
            "relationships": {
                "parent": {
                    "data": {
                        "type": "geo-location",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/3\/parent"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/3"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations?page[number]=4"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/geo-locations

Query Parameters

Parameter Status Description
filter[category] optional Filter specific GeoLocation category.
filter[name] optional Find GeoLocation with given name.
filter[code] optional Filter on specific GeoLocation code.
filter[parent] optional Filter on specific GeoLocation parent_id.
filter[parent_id] optional Filter on specific GeoLocation parent_id.
filter[link_id] optional Filter on specific GeoLocation link_id.
filter[customer] optional Find GeoLocations for given Customer.
filter[customer_id] optional Find GeoLocations for given Customer.

POST GeoLocation


Requires authentication

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"geo-locations","attributes":{"category":"street_geo_location","name":"Example Aalst","code":"9300","external_id":"123456789"},"relationships":{"parent":{"data":{"id":1,"type":"geo-locations"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "geo-locations",
        "attributes": {
            "category": "street_geo_location",
            "name": "Example Aalst",
            "code": "9300",
            "external_id": "123456789"
        },
        "relationships": {
            "parent": {
                "data": {
                    "id": 1,
                    "type": "geo-locations"
                }
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "geo-locations",
        "id": 1,
        "attributes": {
            "created_at": "2012-09-18T09:38:58+00:00",
            "updated_at": "2015-06-22T09:45:15+00:00",
            "deleted_at": null,
            "category": "country_geo_location",
            "name": "België",
            "external_id": null,
            "code": null
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.name": [
            "The data.attributes.name field is required."
        ],
        "data.type": [
            "The data.type type field is required."
        ]
    }
}

HTTP Request

POST api/v1/geo-locations

Body Parameters

Parameter Type Status Description
data.type string required Type must be geo-locations.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.name string required name of this GeoLocation.
data.attributes.code optional optional field code.
data.attributes.external_id optional optional field external_id.
data.relationships.parent.data.id integer optional optional Parent geoLocation.
data.relationships.parent.data.type string optional optional Must be geo-locations.

PATCH GeoLocation


Requires authentication updates a specific geoLocation

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":"1","type":"geo-locations","attributes":{"category":"street_geo_location","name":"Example Aalst","code":"9300","external_id":"123456789"},"relationships":{"parent":{"data":{"id":1,"type":"geo-locations"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": "1",
        "type": "geo-locations",
        "attributes": {
            "category": "street_geo_location",
            "name": "Example Aalst",
            "code": "9300",
            "external_id": "123456789"
        },
        "relationships": {
            "parent": {
                "data": {
                    "id": 1,
                    "type": "geo-locations"
                }
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "geo-locations",
        "id": 1,
        "attributes": {
            "created_at": "2012-09-18T09:38:58+00:00",
            "updated_at": "2015-06-22T09:45:15+00:00",
            "deleted_at": null,
            "category": "country_geo_location",
            "name": "België",
            "external_id": null,
            "code": null
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.name": [
            "The data.attributes.name field is required."
        ],
        "data.type": [
            "The data.type type field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/geo-locations/{geoLocation}

Body Parameters

Parameter Type Status Description
data.id string required id must be a valid GeoLocation id.
data.type string required Type must be geo-locations.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.name string required name of this GeoLocation.
data.attributes.code optional optional field code.
data.attributes.external_id optional optional field external_id.
data.relationships.parent.data.id integer optional optional Parent geoLocation.
data.relationships.parent.data.type string optional optional Must be geo-locations.

GET GeoLocation


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "geo-locations",
        "id": 1,
        "attributes": {
            "created_at": "2012-09-18T09:38:58+00:00",
            "updated_at": "2015-06-22T09:45:15+00:00",
            "deleted_at": null,
            "category": "country_geo_location",
            "name": "België",
            "external_id": null,
            "code": null
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/1"
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations?size=1&page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/geo-locations/{geoLocation}

GET GeoLocations from Parent GeoLocation


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations/1/geo-locations? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations/1/geo-locations");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 7,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "geo-locations",
            "id": 7,
            "attributes": {
                "created_at": "2012-09-18T09:38:58+00:00",
                "updated_at": "2015-06-22T09:45:15+00:00",
                "deleted_at": null,
                "category": "city_geo_location",
                "name": "Aalst",
                "external_id": null,
                "code": null
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/7"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/1\/geo-locations?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/1\/geo-locations?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/1\/geo-locations?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/1\/geo-locations?size=1&page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/geo-locations/{geoLocation}/geo-locations

Query Parameters

Parameter Status Description
filter[category] optional Filter specific GeoLocation category.
filter[name] optional Find GeoLocation with given name.
filter[code] optional Filter on specific GeoLocation code.
filter[parent_id] optional Filter on specific GeoLocation parent_id.
filter[link_id] optional Filter on specific GeoLocation link_id.
filter[customer_id] optional Find GeoLocations for given Customer.

GET GeoLocation parent


Requires authentication Fetch geo-location parent.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations/1/parent" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/geo-locations/1/parent");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "geo-location",
        "id": 8,
        "attributes": {
            "created_at": "2016-01-12T14:54:53+00:00",
            "updated_at": "2017-10-24T10:48:28+00:00",
            "deleted_at": null,
            "link_id": null,
            "category": "city_geo_location",
            "name": "Essen",
            "external_id": "Essen",
            "code": "2000"
        },
        "relationships": {
            "parent": {
                "data": {
                    "type": "geo-location",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/8\/parent"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/8"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/geo-locations/{geoLocation}/parent

GET GeoLocations from a Poi


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/geo-locations" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/geo-locations");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 3,
            "total": 3,
            "last_page": 1
        }
    },
    "errors": null,
    "data": [
        {
            "type": "geo-location",
            "id": 1,
            "attributes": {
                "created_at": "2001-01-01T12:00:00+00:00",
                "updated_at": "2001-01-01T12:00:00+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "country_geo_location",
                "name": "Somewhere over the rainbow",
                "external_id": null,
                "code": null
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/geo-locations",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/geo-locations?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/174\/geo-locations?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/pois/{poi}/geo-locations

GroupSetting

Endpoints related to fetching and managing GroupSetting entities.

Class GroupSettingController

GET GroupSettings


Requires authentication Endpoint to retrieve a paginated response of GroupSetting entities.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/group-settings? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/group-settings");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 3,
            "total": 3,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "group-setting",
            "id": 6,
            "attributes": {
                "created_at": "2020-05-08T06:39:38+00:00",
                "updated_at": "2020-05-08T06:39:38+00:00",
                "deleted_at": null,
                "id": 6,
                "group_id": 6,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/group-settings\/6"
            }
        },
        {
            "type": "group-setting",
            "id": 7,
            "attributes": {
                "created_at": "2020-05-08T06:39:38+00:00",
                "updated_at": "2020-05-08T06:39:38+00:00",
                "deleted_at": null,
                "id": 7,
                "group_id": 7,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/group-settings\/7"
            }
        },
        {
            "type": "group-setting",
            "id": 8,
            "attributes": {
                "created_at": "2020-05-08T06:39:38+00:00",
                "updated_at": "2020-05-08T06:39:38+00:00",
                "deleted_at": null,
                "id": 8,
                "group_id": 8,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/group-settings\/8"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/group-settings",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/group-settings?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/group-settings?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/group-settings

Query Parameters

Parameter Status Description
filter[id] optional Search for 1 or more GroupSetting entities.
filter[group] optional Search for GroupSetting entities belonging to a specific Group. Multiple values are allowed.
filter[from] optional Filter GroupSettings on a given from date. Multiple values are allowed.
filter[from_min] optional Filter GroupSettings having a from date greater than or equal to the given value.
filter[from_max] optional Filter GroupSettings having a from date lesser than or equal to the given value.
filter[until] optional Filter GroupSettings on a given until date. Multiple values are allowed.
filter[until_min] optional Filter GroupSettings having an until date greater than or equal to the given value.
filter[until_max] optional Filter GroupSettings having an until date lesser than or equal to the given value.

POST GroupSetting

Endpoint to create a new GroupSetting entity.

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/group-settings" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"molestias","attributes":{"from":"molestiae","until":"ut","properties":[]}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/group-settings");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "molestias",
        "attributes": {
            "from": "molestiae",
            "until": "ut",
            "properties": []
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "group-setting",
        "id": 407,
        "attributes": {
            "created_at": "2020-05-08T13:17:47+00:00",
            "updated_at": "2020-05-08T13:17:47+00:00",
            "deleted_at": null,
            "properties": [],
            "from": "2020-05-08 00:00:00",
            "until": null,
            "group_id": 403,
            "id": 407
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/group-settings\/407"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field must be present."
        ],
        "data.attributes.until": [
            "The data.attributes.until field must be present."
        ],
        "data.attributes.properties": [
            "The data.attributes.properties field must be present."
        ],
        "data.relationships": [
            "The data.relationships field must be present."
        ],
        "data.relationships.group": [
            "The data.relationships.group field must be present."
        ],
        "data.relationships.group.data": [
            "The data.relationships.group.data field must be present."
        ]
    }
}

HTTP Request

POST api/v1/group-settings

Body Parameters

Parameter Type Status Description
data.type string required The type of the entity. Should match group-setting
data.attributes.from date required The from date.
data.attributes.until date required The until date.
data.attributes.properties array optional required. An array of properties.

GET GroupSetting


Requires authentication Endpoint to retrieve a single GroupSetting entity.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/group-settings/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/group-settings/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "group-setting",
        "id": 33,
        "attributes": {
            "created_at": "2020-05-08T07:01:54+00:00",
            "updated_at": "2020-05-08T07:01:54+00:00",
            "deleted_at": null,
            "id": 33,
            "group_id": 33,
            "from": null,
            "until": null,
            "properties": []
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/group-settings\/33"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/group-settings/{groupSetting}

PATCH GroupSetting


Requires authentication Endpoint to update a single GroupSetting entity.

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/group-settings/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"id":14,"type":"labore","attributes":{"from":"ab","until":"esse"},"relationships":{"groups":{"data":{"id":11,"type":"voluptatem"}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/group-settings/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "id": 14,
    "type": "labore",
    "attributes": {
        "from": "ab",
        "until": "esse"
    },
    "relationships": {
        "groups": {
            "data": {
                "id": 11,
                "type": "voluptatem"
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "group-setting",
        "id": 33,
        "attributes": {
            "created_at": "2020-05-08T07:01:54+00:00",
            "updated_at": "2020-05-08T07:01:54+00:00",
            "deleted_at": null,
            "id": 33,
            "group_id": 33,
            "from": null,
            "until": null,
            "properties": []
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/group-settings\/33"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The data.id field is required."
        ],
        "data.type": [
            "The data.type field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/group-settings/{groupSetting}

Body Parameters

Parameter Type Status Description
id integer required The id of the GroupSetting entity that needs to be updated. Should match the value in the route.
type string required The type of the GroupSetting entity. Should match group-setting
attributes.from date optional nullable optional The from date for the GroupSetting entity. Is optional and can be nullable.
attributes.until nullable optional date optional The until date for the GroupSetting entity. Is optional and can be nullable. Should be after attributes.from.
relationships.groups.data.id integer optional optional The id of the Group entity that should be attached to the GroupSetting entity. Should exist in the api_groups table and not be trashed.
relationships.groups.data.type string optional optional The type of the Group entity. Should match group when present.

DELETE GroupSetting


Requires authentication Endpoint to delete a GroupSetting entity.

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/group-settings/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/group-settings/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v1/group-settings/{groupSetting}

Group entity related requests.

API Calls for retrieving and managing Group resources.

Class GroupController

GET Group resources


Requires authentication Endpoint to retrieve a paginated result of Group entities.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/groups? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/groups");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 2,
            "total": 2,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "group",
            "id": 48,
            "attributes": {
                "created_at": "2020-05-07 08:30:01",
                "updated_at": "2020-05-07 08:30:01",
                "deleted_at": null,
                "id": 48,
                "category": "enim est",
                "properties": []
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/groups\/48"
            }
        },
        {
            "type": "group",
            "id": 49,
            "attributes": {
                "created_at": "2020-05-07 08:30:01",
                "updated_at": "2020-05-07 08:30:01",
                "deleted_at": null,
                "id": 49,
                "category": "eligendi ipsam",
                "properties": []
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/groups\/49"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/groups",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/groups?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/groups?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/groups

Query Parameters

Parameter Status Description
filter[id] optional Filter on resources by 1 or multiple id's. Multiple values allowed.
filter[category] optional Filter resources by category. Multiple values allowed.

POST Group


Requires authentication Endpoint to create a new Group entity.

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/groups" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"eum","attributes":{"category":"<code>shared-product-group<\/code>.","properties":[]}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/groups");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "eum",
        "attributes": {
            "category": "<code>shared-product-group<\/code>.",
            "properties": []
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "group",
        "id": 239,
        "attributes": {
            "created_at": "2020-05-07T10:01:43+00:00",
            "updated_at": "2020-05-07T10:01:43+00:00",
            "deleted_at": null,
            "properties": [],
            "category": "shared_product_group",
            "id": 239
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/groups\/239"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.properties": [
            "The data.attributes.properties field must be present."
        ]
    }
}

HTTP Request

POST api/v1/groups

Body Parameters

Parameter Type Status Description
data.type string optional required. Type must match group.
data.attributes.category string required Category should be in the allowed categories of the Group entity.
data.attributes.properties array required An array of properties is supported.

GET Group


Requires authentication Endpoint to retrieve a single Group entity.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/groups/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/groups/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "group",
        "id": 60,
        "attributes": {
            "created_at": "2020-05-07 08:32:29",
            "updated_at": "2020-05-07 08:32:29",
            "deleted_at": null,
            "id": 60,
            "category": "quidem enim",
            "properties": []
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/groups\/60"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/groups/{group}

PATCH Group


Requires authentication Endpoint to update a specific Group entity.

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/groups/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":13,"type":"est","attributes":{"category":"<code>shared-product-group<\/code>","properties":[]}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/groups/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": 13,
        "type": "est",
        "attributes": {
            "category": "<code>shared-product-group<\/code>",
            "properties": []
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "group",
        "id": 60,
        "attributes": {
            "created_at": "2020-05-07 08:32:29",
            "updated_at": "2020-05-07 08:32:29",
            "deleted_at": null,
            "id": 60,
            "category": "quidem enim",
            "properties": []
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/groups\/60"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The data.id field is required."
        ],
        "data.type": [
            "The data.type field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/groups/{group}

Body Parameters

Parameter Type Status Description
data.id integer required The ID of the entity that should be updated. Needs to match the one in the route.
data.type string required Should match group.
data.attributes.category string optional optional The (new) category value for the entity.
data.attributes.properties array optional optional The (new) properties for the entity.

DELETE Group


Requires authentication Endpoint to delete a specific Group.

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/groups/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/groups/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v1/groups/{group}

Guidelines

API calls for managing Guidelines

Available categories:

Name Description
other_garbage_event_guideline
action_event_guideline

Allowed filters:

?filter[id]={guidelineId}

?filter[category]={categoryName}

?filter[profile]={profileId}

GET Guidelines


Requires authentication returns all guidelines

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/guidelines? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/guidelines");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "guideline",
            "id": 1,
            "attributes": {
                "created_at": "2017-11-27T16:16:23+00:00",
                "updated_at": "2017-11-27T16:16:23+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "other_garbage_event_guideline",
                "description": "Bouw en sloopafval, stenen, grond, zand, glas ..."
            },
            "relationships": {
                "profile": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 116
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines\/1\/profiles"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines?size=1&page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines?size=1&page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/guidelines

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific guideline category.
filter[link_id] optional Find Guidelines for given link id.
filter[profile] optional Find Guidelines for given Profile.
filter[poi_id] optional Find Guidelines for a given Poi.

POST Guideline


Requires authentication creates a specific guideline

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/guidelines" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"guidelines","attributes":{"category":"other_garbage_event_guideline","description":"Example guideline"},"relationships":{"profiles":{"data":[{"id":2,"type":"profile"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/guidelines");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "guidelines",
        "attributes": {
            "category": "other_garbage_event_guideline",
            "description": "Example guideline"
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "id": 2,
                        "type": "profile"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "guideline",
        "id": 2,
        "attributes": {
            "created_at": "2019-07-08T11:42:35+00:00",
            "updated_at": "2019-07-08T11:42:35+00:00",
            "deleted_at": null,
            "link_id": null,
            "category": "other_garbage_event_guideline",
            "description": "testdescription"
        },
        "relationships": {
            "profile": {
                "data": [
                    {
                        "type": "profile",
                        "id": 116
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/guilines\/2\/profiles"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/guilines\/2"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.description": [
            "The data.attributes.description field is required."
        ],
        "data.relationships.profile.data.type": [
            "The data.relationships.profile.data.type field is required."
        ],
        "data.relationships.profile.data.id": [
            "The data.relationships.profile.data.id field is required."
        ]
    }
}

HTTP Request

POST api/v1/guidelines

Body Parameters

Parameter Type Status Description
data.type string required Type must be guideline.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.description string required Description of this Guideline.
data.relationships.profiles.data.*.id integer optional optional Profile id.
data.relationships.profiles.data.*.type string optional optional Profile type must be profile.

GET guideline


Requires authentication returns a specific guideline

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/guidelines/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/guidelines/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "guideline",
        "id": 1,
        "attributes": {
            "created_at": "2017-11-27T16:16:23+00:00",
            "updated_at": "2017-11-27T16:16:23+00:00",
            "deleted_at": null,
            "link_id": null,
            "category": "other_garbage_event_guideline",
            "description": "Bouw en sloopafval, stenen, grond, zand, glas ..."
        },
        "relationships": {
            "profile": {
                "data": [
                    {
                        "type": "profile",
                        "id": 116
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines\/1\/profiles"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/guidelines/{guideline}

PATCH Guideline


Requires authentication updates a specific guideline

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/guidelines/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":1,"type":"guidelines","attributes":{"category":"other_garbage_event_guideline","description":"Example guideline"},"relationships":{"profiles":{"data":[{"id":2,"type":"profile"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/guidelines/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": 1,
        "type": "guidelines",
        "attributes": {
            "category": "other_garbage_event_guideline",
            "description": "Example guideline"
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "id": 2,
                        "type": "profile"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "guideline",
        "id": 1,
        "attributes": {
            "created_at": "2016-03-09T14:01:39+00:00",
            "updated_at": "2018-04-09T12:40:29+00:00",
            "deleted_at": null,
            "link_id": null,
            "category": "other_garbage_event_guideline",
            "description": "Bouw en sloopafval, stenen, grond, zand, glas ..."
        },
        "relationships": {
            "profile": {
                "data": [
                    {
                        "type": "profile",
                        "id": 116
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines\/1\/profiles"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.description": [
            "The data.attributes.description field is required."
        ],
        "data.relationships.profile.data.type": [
            "The data.relationships.profile.data.type field is required."
        ],
        "data.relationships.profile.data.id": [
            "The data.relationships.profile.data.id field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/guidelines/{guideline}

Body Parameters

Parameter Type Status Description
data.id integer required Guideline ID to patch.
data.type string required Type must be guideline.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.description string required Description of this guideline.
data.relationships.profiles.data.*.id integer optional optional Profile id.
data.relationships.profiles.data.*.type string optional optional Profile type must be profile.

GET Guidelines from Poi


Requires authentication returns guidelines linked to a specific poi

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/guidelines? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/guidelines");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "guideline",
            "id": 1,
            "attributes": {
                "created_at": "2017-11-27T16:16:23+00:00",
                "updated_at": "2017-11-27T16:16:23+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "other_garbage_event_guideline",
                "description": "Bouw en sloopafval, stenen, grond, zand, glas ..."
            },
            "relationships": {
                "profile": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 116
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines\/1\/profiles"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/guidelines\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/guidelines?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/guidelines?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/guidelines?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/guidelines?size=1&page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/pois/{poi}/guidelines

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific guideline category.
filter[link_id] optional Find Guidelines for given link id.
filter[profile] optional Find Guidelines for given Profile.

GET Guidelines from Profile


Requires authentication returns profiles linked to a specific profile

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/profiles/1/guidelines? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/profiles/1/guidelines");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "guideline",
            "id": 1,
            "attributes": {
                "created_at": "2017-11-27T16:16:23+00:00",
                "updated_at": "2017-11-27T16:16:23+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "other_garbage_event_guideline",
                "description": "Bouw en sloopafval, stenen, grond, zand, glas ..."
            },
            "relationships": {
                "profile": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 116
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/guidelines\/1\/profiles"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/116\/guidelines\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/116\/guidelines?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/116\/guidelines?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/116\/guidelines?size=1&page[number]=1",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/116\/guidelines?size=1&page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/profiles/{profile}/guidelines

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific guideline category.
filter[link_id] optional Find Guidelines for given link id.
filter[poi_id] optional Find Guidelines for a given Poi.

Module Requests

API calls for managing Modules

Available categories:

Name Description
ciweb_module

GET modules from Customer


Requires authentication returns modules linked to a specific customer

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/modules" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/modules");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "module",
        "id": 1,
        "attributes": {
            "created_at": "2019-06-28T05:57:54+00:00",
            "updated_at": "2019-06-28T05:57:54+00:00",
            "deleted_at": null,
            "name": "actions",
            "category": "ciweb_module"
        },
        "relationships": {
            "customers": {
                "data": [
                    {
                        "type": "customer",
                        "id": 6
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/modules\/1\/customers"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/modules\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/customers/{customer}/modules

GET modules


Requires authentication returns all modules

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/modules? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/modules");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 19,
            "total": 19,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "module",
            "id": 1,
            "attributes": {
                "created_at": "2019-06-28T05:57:54+00:00",
                "updated_at": "2019-06-28T05:57:54+00:00",
                "deleted_at": null,
                "name": "actions",
                "category": "ciweb_module"
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/modules\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/modules",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/modules?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/modules?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/modules

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific calendar category.

POST module


Requires authentication creates a specific module

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/modules" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"module","attributes":{"category":"ciweb_module","name":"example_module"},"relationships":{"customers":{"data":[{"id":2,"type":"customer"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/modules");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "module",
        "attributes": {
            "category": "ciweb_module",
            "name": "example_module"
        },
        "relationships": {
            "customers": {
                "data": [
                    {
                        "id": 2,
                        "type": "customer"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "module",
        "id": 1,
        "attributes": {
            "created_at": "2019-06-28T05:57:54+00:00",
            "updated_at": "2019-06-28T05:57:54+00:00",
            "deleted_at": null,
            "name": "actions",
            "category": "ciweb_module"
        },
        "relationships": {
            "customers": {
                "data": [
                    {
                        "type": "customer",
                        "id": 6
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/modules\/1\/customers"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/modules\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.name": [
            "The data.attributes.name field is required."
        ]
    }
}

HTTP Request

POST api/v1/modules

Body Parameters

Parameter Type Status Description
data.type string required Type must be module.
data.attributes array required
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.name string required Name of this module.
data.relationships.customers.data array optional optional
data.relationships.customers.data.*.id integer optional optional Profile id.
data.relationships.customers.data.*.type string required Customer type must be customer.

PATCH module


Requires authentication updates a specific module

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/modules/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"module","id":1,"attributes":{"category":"ciweb_module","name":"example_module"},"relationships":{"customers":{"data":[{"id":2,"type":"customer"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/modules/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "module",
        "id": 1,
        "attributes": {
            "category": "ciweb_module",
            "name": "example_module"
        },
        "relationships": {
            "customers": {
                "data": [
                    {
                        "id": 2,
                        "type": "customer"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "module",
        "id": 1,
        "attributes": {
            "created_at": "2019-06-28T05:57:54+00:00",
            "updated_at": "2019-06-28T05:57:54+00:00",
            "deleted_at": null,
            "name": "actions",
            "category": "ciweb_module"
        },
        "relationships": {
            "customers": {
                "data": [
                    {
                        "type": "customer",
                        "id": 6
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/modules\/1\/customers"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/modules\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type value does not match required value."
        ],
        "data.attributes.category": [
            "The selected data.attributes.category is invalid."
        ]
    }
}

HTTP Request

PATCH api/v1/modules/{module}

Body Parameters

Parameter Type Status Description
data.type string optional optional Type must be module.
data.id integer required The id must match the url id.
data.attributes.category string optional optional One of the categories mentioned at the top of this page.
data.attributes.name string optional optional Name of this module.
data.relationships.customers.data.*.id integer optional optional Profile id.
data.relationships.customers.data.*.type string optional optional Customer type must be customer.

GET module


Requires authentication returns a specific module

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/modules/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/modules/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "module",
        "id": 1,
        "attributes": {
            "created_at": "2019-06-28T05:57:54+00:00",
            "updated_at": "2019-06-28T05:57:54+00:00",
            "deleted_at": null,
            "name": "actions",
            "category": "ciweb_module"
        },
        "relationships": {
            "customers": {
                "data": [
                    {
                        "type": "customer",
                        "id": 6
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/modules\/1\/customers"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/modules\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/modules/{module}

Option

API calls for managing Options

Available categories:

NameDescription
complaint_event_origin
complaint_event_source
complaint_event_profile_location
complaint_event_profile_subject
complaint_event_profile_description
other_garbage_event_source
other_garbage_event_origin
other_garbage_event_reason
bin_product_profile_description
bin_product_profile_fraction
bin_product_profile_volume
bin_product_profile_designation
chipcard_product_profile_description
chipcard_product_profile_model
other_garbage_event_profile_description
ciaccess_product_profile_system_brand
ciaccess_product_profile_description
ciaccess_product_profile_column_kind
ciaccess_product_profile_inspection_door
ciaccess_product_profile_opening_kind
ciaccess_product_profile_opening_volume
ciaccess_product_profile_emptying_system
ciaccess_product_profile_pedestrian_platform
ciaccess_product_profile_compartments_count
ciaccess_product_profile_waste_kind
ciaccess_product_profile_volume
ciaccess_product_profile_ral_color
ciaccess_product_profile_key_number
ident_system_profile_brand
ident_system_profile_power_supply
ident_system_profile_type_description
ident_system_profile_lock_type
action_event_source
action_event_origin
action_event_team
ciaccess_action_event_source
ciaccess_action_event_origin
ciaccess_complaint_event_source
ciaccess_complaint_event_origin
ciaccess_info_request_event_source
ciaccess_info_request_event_origin
info_request_event_source
info_request_event_origin
info_request_event_profile_description
action_event_profile_name
poi_category

GET all available options from a customer


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/options? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/options");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 698,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "option",
            "id": 1,
            "attributes": {
                "created_at": "2012-09-25T17:48:14+00:00",
                "updated_at": "2016-03-03T09:17:50+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "other_garbage_event_origin",
                "name": "Burger"
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/options?page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The selected data.type is invalid."
        ],
        "data.attributes.category": [
            "The selected data.attributes.category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/customers/{customer}/options

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific option category.
filter[link_id] optional Find option with given legacy id as link_id.
filter[parent_id] optional Find option with given parent_id.
filter[name] optional Find option with given name.
filter[poi_id] optional Find option with given name.

GET Options


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/options? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/options");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 699,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "option",
            "id": 1,
            "attributes": {
                "created_at": "2012-09-25T17:48:14+00:00",
                "updated_at": "2019-07-19T11:06:24+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "other_garbage_event_origin",
                "name": "Burger"
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/options",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/options?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/options?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/options?page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The selected data.type is invalid."
        ],
        "data.attributes.category": [
            "The selected data.attributes.category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/options

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific option category.
filter[link_id] optional Find option with given legacy id as link_id.
filter[parent_id] optional Find option with given parent_id.
filter[name] optional Find option with given name.
filter[poi_id] optional Find option with given name.

POST Option


Requires authentication

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/options" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"option","attributes":{"category":"bin_product_profile_volume","name":"Event profile subject something"},"relationships":{"parent":{"data":{"id":1,"type":"option"}},"children":{"data":[{"":"et","id":2,"type":"option"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/options");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "option",
        "attributes": {
            "category": "bin_product_profile_volume",
            "name": "Event profile subject something"
        },
        "relationships": {
            "parent": {
                "data": {
                    "id": 1,
                    "type": "option"
                }
            },
            "children": {
                "data": [
                    {
                        "": "et",
                        "id": 2,
                        "type": "option"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "option",
        "id": 717,
        "attributes": {
            "created_at": "2019-07-19T11:10:39+00:00",
            "updated_at": "2019-07-19T11:10:39+00:00",
            "deleted_at": null,
            "link_id": null,
            "category": "complaint_event_origin",
            "name": "test"
        },
        "relationships": {
            "parent": {
                "data": {
                    "type": "option",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/717\/parent"
                }
            },
            "children": {
                "data": [
                    {
                        "type": "option",
                        "id": 2,
                        "option_type": "option"
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/717\/children"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/717"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.name": [
            "The data.attributes.name field is required."
        ],
        "data.relationships.parent.data.type": [
            "The data.relationships.parent.data.type must be 'option'."
        ],
        "data.relationships.parent.data.id": [
            "The data.relationships.parent.data.id must be an Option that exists in the database."
        ],
        "data.relationships.children.children.": [
            "required_with:data.relationships.children must be an array"
        ],
        "data.relationships.children.children..type": [
            "The data.relationships.parent.data.type must be 'option'."
        ],
        "data.relationships.children.data..id": [
            "The data.relationships.children.data..id must be an Option that exists in the database."
        ]
    }
}

HTTP Request

POST api/v1/options

Body Parameters

Parameter Type Status Description
data.type string required Type must be option.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.name string required Name of this option.
data.relationships.parent.data.id integer optional optional Parent option.
data.relationships.parent.data.type string optional optional Must be option.
data.relationships.children.data.[] optional optional array with optional multiple Child options (pure optional = not required)
data.relationships.children.data.*.id integer optional optional Option id.
data.relationships.children.data.*.type string optional optional Option type must be option.

PATCH Option


Requires authentication updates a specific option

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/options/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"option","id":1,"attributes":{"category":"bin_product_profile_volume","name":"Event profile subject something"},"relationships":{"parent":{"data":{"id":1,"type":"option"}},"children":{"data":[{"":"libero","id":2,"type":"option"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/options/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "option",
        "id": 1,
        "attributes": {
            "category": "bin_product_profile_volume",
            "name": "Event profile subject something"
        },
        "relationships": {
            "parent": {
                "data": {
                    "id": 1,
                    "type": "option"
                }
            },
            "children": {
                "data": [
                    {
                        "": "libero",
                        "id": 2,
                        "type": "option"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "option",
        "id": 717,
        "attributes": {
            "created_at": "2019-07-19T11:10:39+00:00",
            "updated_at": "2019-07-19T11:10:39+00:00",
            "deleted_at": null,
            "link_id": null,
            "category": "complaint_event_origin",
            "name": "test"
        },
        "relationships": {
            "parent": {
                "data": {
                    "type": "option",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/717\/parent"
                }
            },
            "children": {
                "data": [
                    {
                        "type": "option",
                        "id": 2,
                        "option_type": "option"
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/717\/children"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/717"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.name": [
            "The data.attributes.name field is required."
        ],
        "data.relationships.parent.data.type": [
            "The data.relationships.parent.data.type must be 'option'."
        ],
        "data.relationships.parent.data.id": [
            "The data.relationships.parent.data.id must be an Option that exists in the database."
        ],
        "data.relationships.children.children.": [
            "required_with:data.relationships.children must be an array"
        ],
        "data.relationships.children.children..type": [
            "The data.relationships.parent.data.type must be 'option'."
        ],
        "data.relationships.children.data..id": [
            "The data.relationships.children.data..id must be an Option that exists in the database."
        ]
    }
}

HTTP Request

PATCH api/v1/options/{option}

Body Parameters

Parameter Type Status Description
data.type string required Type must be option.
data.id integer required The id must match the url id.
data.attributes.category string optional optional One of the categories mentioned at the top of this page.
data.attributes.name string optional optional Name of this option.
data.relationships.parent.data.id integer optional optional Parent option.
data.relationships.parent.data.type string optional optional Must be option.
data.relationships.children.data.[] optional optional array with optional multiple Child options (pure optional = not required)
data.relationships.children.data.*.id integer optional optional Option id.
data.relationships.children.data.*.type string optional optional Option type must be option.

GET a specific Option


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/options/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/options/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "option",
        "id": 1,
        "attributes": {
            "created_at": "2012-09-25T17:48:14+00:00",
            "updated_at": "2019-07-19T11:06:24+00:00",
            "deleted_at": null,
            "link_id": null,
            "category": "other_garbage_event_origin",
            "name": "Burger"
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The selected data.type is invalid."
        ],
        "data.attributes.category": [
            "The selected data.attributes.category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/options/{option}

GET the list of children from a specific Option


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/options/1/children" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/options/1/children");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "option",
            "id": 1,
            "attributes": {
                "created_at": "2012-09-25T17:48:14+00:00",
                "updated_at": "2019-07-19T11:06:24+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "other_garbage_event_origin",
                "name": "Burger"
            },
            "relationships": {
                "parent": {
                    "data": {
                        "type": "option",
                        "id": 2
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/1\/parent"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/2\/children",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/options\/2\/children?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/options\/2\/children?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/options/{option}/children

GET the parent from a specific Option


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/options/1/parent" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/options/1/parent");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "option",
        "id": 2,
        "attributes": {
            "created_at": "2012-09-25T17:48:22+00:00",
            "updated_at": "2019-07-19T11:10:39+00:00",
            "deleted_at": null,
            "link_id": null,
            "category": "other_garbage_event_origin",
            "name": "Gemeente"
        },
        "relationships": {
            "parent": {
                "data": {
                    "type": "option",
                    "id": 717
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/2\/parent"
                }
            },
            "children": {
                "data": [
                    {
                        "type": "option",
                        "id": 1,
                        "option_type": "option"
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/2\/children"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/2"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/options/{option}/parent

GET all available options a poi can use


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/options? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/options");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "option",
        "id": 2,
        "attributes": {
            "created_at": "2012-09-25T17:48:22+00:00",
            "updated_at": "2019-07-19T11:10:39+00:00",
            "deleted_at": null,
            "link_id": null,
            "category": "other_garbage_event_origin",
            "name": "Gemeente"
        },
        "relationships": {
            "parent": {
                "data": {
                    "type": "option",
                    "id": 717
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/2\/parent"
                }
            },
            "children": {
                "data": [
                    {
                        "type": "option",
                        "id": 1,
                        "option_type": "option"
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/2\/children"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/2"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The selected data.type is invalid."
        ],
        "data.attributes.category": [
            "The selected data.attributes.category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/pois/{poi}/options

Query Parameters

Parameter Status Description
filter[category] optional Filter specific option category.

Option Validators.

All the endpoints for fetching and managing the validators for a specific option.

Class OptionValidatorsController

GET Validators by Option

Endpoint to get all the Validator entities attached to a specific option.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/options/1/validators" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/options/1/validators");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 3,
            "total": 3,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "validator",
            "id": 244,
            "attributes": {
                "created_at": "2020-02-24T10:40:39+00:00",
                "updated_at": "2020-02-24T10:40:39+00:00",
                "deleted_at": null,
                "entity_type": "product",
                "field": "chip_code",
                "validation_rules": [
                    "required"
                ],
                "priority": 0
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 524
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/244\/customers"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/244"
            }
        },
        {
            "type": "validator",
            "id": 245,
            "attributes": {
                "created_at": "2020-02-24T10:40:39+00:00",
                "updated_at": "2020-02-24T10:40:39+00:00",
                "deleted_at": null,
                "entity_type": "product",
                "field": "chip_code",
                "validation_rules": [
                    "required"
                ],
                "priority": 0
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 525
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/245\/customers"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/245"
            }
        },
        {
            "type": "validator",
            "id": 246,
            "attributes": {
                "created_at": "2020-02-24T10:40:39+00:00",
                "updated_at": "2020-02-24T10:40:39+00:00",
                "deleted_at": null,
                "entity_type": "product",
                "field": "chip_code",
                "validation_rules": [
                    "required"
                ],
                "priority": 0
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 526
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/246\/customers"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/246"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/validators",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/validators?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/validators?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/options/{option}/validators

PersonPoiHistory Requests

API calls for managing PersonPoiHistory

GET PersonPoiHistories


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 7,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "person-poi-history",
            "id": 1,
            "attributes": {
                "created_at": "2019-06-27T09:54:15+00:00",
                "updated_at": "2019-06-27T09:54:15+00:00",
                "deleted_at": null,
                "from": "2019-01-01",
                "role": null,
                "category": "residential_poi",
                "main_option_id": 1234,
                "sub_option_id": 2456,
                "person_count": 4
            },
            "relationships": {
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 18783
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1\/poi"
                    }
                },
                "person": {
                    "data": {
                        "type": "person",
                        "id": 32769
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1\/person"
                    },
                    "mainOption": {
                        "data": {
                            "type": "option",
                            "id": 1234
                        },
                        "links": {
                            "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1\/main-option"
                        }
                    },
                    "subOption": {
                        "data": {
                            "type": "option",
                            "id": 2456
                        },
                        "links": {
                            "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1\/sub-option"
                        }
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history?size=1&page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/person-poi-history

Query Parameters

Parameter Status Description
filter[id] optional PersonPoiHistory with a specific id.
filter[from] optional PersonPoiHistory on a specific from date.
filter[from_between] optional PersonPoiHistory until a certain date.
filter[until] optional PersonPoiHistory on a specific until date.
filter[until_between] optional Until field between two dates (Excludes NULL).
filter[from_min] optional PersonPoiHistory from a certain date.
filter[from_max] optional PersonPoiHistory until a certain date.
filter[on_date] optional The PersonPoiHistory that is active on the given date.
filter[parent_person] optional Find PersonPoiHistory for a given parent.
filter[role] optional Find PersonPoiHistory for a given role.
filter[customer] optional Find PersonPoiHistory for a given customer (through poi relation).
filter[created_at] optional PersonPoiHistory for a given created at timestamp.
filter[created_at_min] optional Created at or after the given timestamp.
filter[created_at_max] optional Created at or before the given timestamp.
filter[created_at_between] optional Created at between two given timestamps (inclusive).
filter[updated_at] optional PersonPoiHistory for a given updated at timestamp.
filter[updated_at_min] optional Updated at or after the given timestamp.
filter[updated_at_max] optional Updated at or before the given timestamp.
filter[updated_at_between] optional Updated at between two given timestamps (inclusive).

POST PersonPoiHistory


Requires authentication

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"person-poi-history","attributes":{"from":"2019-05-10","until":"2019-06-10"},"relationships":{"poi":{"data":{"id":1,"type":"poi"}},"person":[{"id":2,"type":"person"}]}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "person-poi-history",
        "attributes": {
            "from": "2019-05-10",
            "until": "2019-06-10"
        },
        "relationships": {
            "poi": {
                "data": {
                    "id": 1,
                    "type": "poi"
                }
            },
            "person": [
                {
                    "id": 2,
                    "type": "person"
                }
            ]
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "person-poi-history",
        "id": 23370,
        "attributes": {
            "created_at": "2019-07-19T10:13:10+00:00",
            "updated_at": "2019-07-19T10:13:10+00:00",
            "deleted_at": null,
            "from": "2019-01-01",
            "until": "2019-01-02",
            "role": "test"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/23370\/poi"
                }
            },
            "person": {
                "data": {
                    "type": "person",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/23370\/person"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/23370"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ],
        "data.relationships.poi.data.id": [
            "The data.relationships.poi.data.id field is required."
        ],
        "data.relationships.person.data": [
            "The data.relationships.person.data field is required."
        ]
    }
}

HTTP Request

POST api/v1/person-poi-history

Body Parameters

Parameter Type Status Description
data.type string required Type must be person-poi-history.
data.attributes.from dateTime optional required.
data.attributes.until dateTime optional optional.
data.relationships.poi.data.id integer required valid poi id.
data.relationships.poi.data.type required optional string. Must be poi.
data.relationships.person.*.id integer required person id.
data.relationships.person.*.type string required person type must be person.

GET PersonPoiHistory


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 7,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "person-poi-history",
        "id": 1,
        "attributes": {
            "created_at": "2019-06-27T09:54:15+00:00",
            "updated_at": "2019-06-27T09:54:15+00:00",
            "deleted_at": null,
            "from": "2019-01-01",
            "role": null
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 18783
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1\/poi"
                }
            },
            "person": {
                "data": {
                    "type": "person",
                    "id": 32769
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1\/person"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1"
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history?size=1&page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/person-poi-history/{personPoiHistory}

PATCH PersonPoiHistory


Requires authentication updates a specific PersonPoiHistory

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":"1","type":"person-poi-history","attributes":{"from":"2019-05-10","until":"2019-06-10"},"relationships":{"poi":{"data":{"id":1,"type":"poi"}},"person":[{"id":2,"type":"person"}]}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": "1",
        "type": "person-poi-history",
        "attributes": {
            "from": "2019-05-10",
            "until": "2019-06-10"
        },
        "relationships": {
            "poi": {
                "data": {
                    "id": 1,
                    "type": "poi"
                }
            },
            "person": [
                {
                    "id": 2,
                    "type": "person"
                }
            ]
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "person-poi-history",
        "id": 23370,
        "attributes": {
            "created_at": "2019-07-19T10:13:10+00:00",
            "updated_at": "2019-07-19T10:14:03+00:00",
            "deleted_at": null,
            "from": "2019-01-01",
            "until": "2019-01-02",
            "role": "test"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/23370\/poi"
                }
            },
            "person": {
                "data": {
                    "type": "person",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/23370\/person"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/23370"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ],
        "data.relationships.poi.data.id": [
            "The data.relationships.poi.data.id field is required."
        ],
        "data.relationships.person.data": [
            "The data.relationships.person.data field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/person-poi-history/{personPoiHistory}

Body Parameters

Parameter Type Status Description
data.id string required id must be a valid PersonPoiHistory id.
data.type string required Type must be person-poi-history.
data.attributes.from dateTime optional required.
data.attributes.until dateTime optional optional.
data.relationships.poi.data.id integer required valid poi id.
data.relationships.poi.data.type required optional string. Must be poi.
data.relationships.person.*.id integer required person id.
data.relationships.person.*.type string required person type must be person.

GET PersonPoiHistory from Person


Requires authentication returns person-poi-histories linked to a specific person

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/persons/1/person-poi-history? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/persons/1/person-poi-history");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 7,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "person-poi-history",
            "id": 1,
            "attributes": {
                "created_at": "2019-06-27T09:54:15+00:00",
                "updated_at": "2019-06-27T09:54:15+00:00",
                "deleted_at": null,
                "from": "2019-01-01",
                "role": null
            },
            "relationships": {
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 18783
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1\/poi"
                    }
                },
                "person": {
                    "data": {
                        "type": "person",
                        "id": 32769
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1\/person"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/1\/person-poi-history?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/1\/person-poi-history?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/1\/person-poi-history?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/1\/person-poi-history?size=1&page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/persons/{person}/person-poi-history

Query Parameters

Parameter Status Description
filter[id] optional PersonPoiHistory with a specific id.
filter[from] optional PersonPoiHistory on a specific from date.
filter[until] optional PersonPoiHistory on a specific until date.
filter[from_min] optional PersonPoiHistory from a certain date.
filter[from_max] optional PersonPoiHistory until a certain date.
filter[on_date] optional The PersonPoiHistory that is active on the given date.
filter[parent_person] optional Find PersonPoiHistory for a given parent.
filter[role] optional Find PersonPoiHistory for a given role.

GET PersonPoiHistories from Poi


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/person-poi-history? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/person-poi-history");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "person-poi-history",
            "id": 20307,
            "attributes": {
                "created_at": "2019-07-18T12:27:15+00:00",
                "updated_at": "2019-07-18T12:27:15+00:00",
                "deleted_at": null,
                "from": "2016-01-01 00:00:00",
                "until": null,
                "role": null
            },
            "relationships": {
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 18783
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/20307\/poi"
                    }
                },
                "person": {
                    "data": {
                        "type": "person",
                        "id": 18765
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/20307\/person"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/person-poi-history\/20307"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/18783\/person-poi-history",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/18783\/person-poi-history?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/18783\/person-poi-history?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/pois/{poi}/person-poi-history

Query Parameters

Parameter Status Description
filter[from] optional PersonPoiHistory on a specific from date.
filter[until] optional PersonPoiHistory on a specific until date.
filter[from_min] optional PersonPoiHistory from a certain date.
filter[from_max] optional PersonPoiHistory until a certain date.
filter[on_date] optional The PersonPoiHistory that is active on the given date.
filter[parent_person] optional Find PersonPoiHistory for a given parent.
filter[role] optional Find PersonPoiHistory for a given role.

Person Requests

API calls for managing Persons

Available categories:

Name Description
CATEGORY_INHABITANT inhabitant_person
CATEGORY_COMPANY company_person
CATEGORY_ANONYMOUS anonymous_person

Get Persons from Customer


Requires authentication Returns all Persons linked to a specific Customer

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/persons" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/persons");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 10000,
            "last_page": 100
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "person",
            "id": 14,
            "attributes": {
                "created_at": "2019-07-04T12:40:41+00:00",
                "updated_at": "2019-07-04T12:40:41+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "inhabitant_person",
                "role": null,
                "first_name": "John",
                "last_name": "Doe",
                "salutation": null,
                "phone": null,
                "fax": null,
                "mobile": null,
                "email": null,
                "identification_number": "",
                "company_name": null,
                "vat": null,
                "gender": null,
                "bic": null,
                "date_of_birth": null,
                "external_id": "1111",
                "properties": null
            },
            "relationships": {
                "profiles": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14\/profiles"
                    }
                },
                "pois": {
                    "data": [
                        {
                            "type": "poi",
                            "id": 30
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14\/pois"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/persons",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/persons?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/persons?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/persons?page[number]=100"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/customers/{customer}/persons

Get Persons from Person Poi History


Requires authentication Returns Persons linked to Person Poi History

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history/1/person" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history/1/person");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "person",
        "id": 1,
        "attributes": {
            "created_at": "2019-07-04T12:40:41+00:00",
            "updated_at": "2019-07-04T12:40:41+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "inhabitant_person",
            "role": null,
            "first_name": "John",
            "last_name": "Doe",
            "salutation": null,
            "phone": null,
            "fax": null,
            "mobile": null,
            "email": null,
            "identification_number": null,
            "company_name": null,
            "vat": null,
            "gender": null,
            "bic": null,
            "date_of_birth": null,
            "external_id": "1",
            "properties": null
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": 1
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/1\/profiles"
                }
            },
            "pois": {
                "data": [
                    {
                        "type": "poi",
                        "id": 17
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/1\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/1"
        }
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/person-poi-history/{personPoiHistory}/person

POST Person


Requires authentication Creates a specific Person

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/persons" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"person","attributes":{"category":"inhabitant_person","first_name":"John","last_name":"Doe","company_name":"Doe","phone":"Example 049839039","salutation":"Example Mr.","fax":"Example 0299030404","mobile":"Example 049839039","email":"Example example@test.local","date_of_birth":"Example 06\/05\/2000","deceased_at":"Example 17\/10\/2078","identification_number":"Example 93051822361","vat":"Example BE03 123 123 123","gender":"Example M","bic":"Example BE03 123 123 123","tags":"Example tag1, tag2","external_id":"Example 9988","properties":"{\"prop\": \"value\"}"},"relationships":{"profiles":{"data":[{"id":2,"type":"profile"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/persons");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "person",
        "attributes": {
            "category": "inhabitant_person",
            "first_name": "John",
            "last_name": "Doe",
            "company_name": "Doe",
            "phone": "Example 049839039",
            "salutation": "Example Mr.",
            "fax": "Example 0299030404",
            "mobile": "Example 049839039",
            "email": "Example example@test.local",
            "date_of_birth": "Example 06\/05\/2000",
            "deceased_at": "Example 17\/10\/2078",
            "identification_number": "Example 93051822361",
            "vat": "Example BE03 123 123 123",
            "gender": "Example M",
            "bic": "Example BE03 123 123 123",
            "tags": "Example tag1, tag2",
            "external_id": "Example 9988",
            "properties": "{\"prop\": \"value\"}"
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "id": 2,
                        "type": "profile"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "person",
        "id": 44645,
        "attributes": {
            "created_at": "2019-07-08T10:14:51+00:00",
            "updated_at": "2019-07-08T10:14:51+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "inhabitant_person",
            "role": null,
            "first_name": "John",
            "last_name": "Doe",
            "salutation": "Mr",
            "phone": "053887766",
            "fax": null,
            "mobile": null,
            "email": "test@test.be",
            "identification_number": null,
            "company_name": null,
            "vat": null,
            "gender": null,
            "bic": null,
            "date_of_birth": null,
            "deceased_at": null,
            "external_id": "1234",
            "properties": null
        },
        "relationships": {
            "profiles": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/44645\/profiles"
                }
            },
            "pois": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1persons\/44645\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/44645"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.relationships.profiles.data": [
            "The data.relationships.profiles.data field is required."
        ]
    }
}

HTTP Request

POST api/v1/persons

Body Parameters

Parameter Type Status Description
data.type string required Type must be person.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.first_name string optional optional required for categories: <inhabitant_person, company_person>.
data.attributes.last_name string optional optional required for categories: <inhabitant_person, company_person>.
data.attributes.company_name string optional optional required for categories: .
data.attributes.phone string optional optional phone of the Person.
data.attributes.salutation string optional optional salutation of the Person.
data.attributes.fax string optional optional fax of the Person.
data.attributes.mobile string optional optional mobile of the Person.
data.attributes.email string optional optional email of the Person.
data.attributes.date_of_birth string optional optional date_of_birth of the Person.
data.attributes.deceased_at string optional optional deceased_at of the Person.
data.attributes.identification_number string optional optional date_of_birth of the Person.
data.attributes.vat string optional optional vat number of the Person.
data.attributes.gender string optional optional gender of the Person.
data.attributes.bic string optional optional bic number of the Person.
data.attributes.tags string optional optional tags of the Person.
data.attributes.external_id string optional optional external_id of the Person.
data.attributes.properties string optional optional properties of the Person.
data.relationships.profiles.data.*.id integer optional optional Profile id.
data.relationships.profiles.data.*.type string optional optional Profile type must be profile.

PATCH Person


Requires authentication Updates a specific Person

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/persons/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"person","id":1,"attributes":{"category":"inhabitant_person"},"relationships":{"profiles":{"data":[{"id":2,"type":"profile"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/persons/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "person",
        "id": 1,
        "attributes": {
            "category": "inhabitant_person"
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "id": 2,
                        "type": "profile"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "person",
        "id": 14,
        "attributes": {
            "created_at": "2019-07-04T12:40:41+00:00",
            "updated_at": "2019-07-04T12:40:41+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "inhabitant_person",
            "role": null,
            "first_name": "John",
            "last_name": "Doe",
            "salutation": "Mr",
            "phone": "053887766",
            "fax": null,
            "mobile": null,
            "email": "test@test.be",
            "identification_number": null,
            "company_name": null,
            "vat": null,
            "gender": null,
            "bic": null,
            "date_of_birth": null,
            "deceased_at": null,
            "external_id": "1234",
            "properties": null
        },
        "relationships": {
            "profiles": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14\/profiles"
                }
            },
            "pois": {
                "data": [
                    {
                        "type": "poi",
                        "id": 30
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": []
}

HTTP Request

PATCH api/v1/persons/{person}

Body Parameters

Parameter Type Status Description
data.type string required Type must be persons.
data.id integer required The id must match the url id.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.relationships.profiles.data.*.id integer optional optional Profile id.
data.relationships.profiles.data.*.type string optional optional Profile type must be profile.

GET Person


Requires authentication returns a specific person

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/persons/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/persons/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "person",
        "id": 14,
        "attributes": {
            "created_at": "2019-07-04T12:40:41+00:00",
            "updated_at": "2019-07-04T12:40:41+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "inhabitant_person",
            "role": null,
            "first_name": "John",
            "last_name": "Doe",
            "salutation": null,
            "phone": null,
            "fax": null,
            "mobile": null,
            "email": null,
            "identification_number": null,
            "company_name": null,
            "vat": null,
            "gender": null,
            "bic": null,
            "date_of_birth": null,
            "deceased_at": null,
            "external_id": "10009",
            "properties": null
        },
        "relationships": {
            "profiles": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14\/profiles"
                }
            },
            "pois": {
                "data": [
                    {
                        "type": "poi",
                        "id": 30
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/persons/{person}

Get Persons from Poi


Requires authentication Returns Persons linked to Poi

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/persons? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/persons");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "person",
        "id": 1,
        "attributes": {
            "created_at": "2019-07-04T12:40:41+00:00",
            "updated_at": "2019-07-04T12:40:41+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "inhabitant_person",
            "role": null,
            "first_name": "John",
            "last_name": "Doe",
            "salutation": null,
            "phone": null,
            "fax": null,
            "mobile": null,
            "email": null,
            "identification_number": null,
            "company_name": null,
            "vat": null,
            "gender": null,
            "bic": null,
            "date_of_birth": null,
            "external_id": "1",
            "properties": null
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": 1
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/1\/profiles"
                }
            },
            "pois": {
                "data": [
                    {
                        "type": "poi",
                        "id": 17
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/1\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/1"
        }
    }
}

HTTP Request

GET api/v1/pois/{poi}/persons

Query Parameters

Parameter Status Description
filter[active_at] optional get the current persons of the Poi.

Poi Allowed profiles

API Calls (v2) for fetching and managing the allowed Profiles for a specific Poi entity.

Class PoiAllowedProfilesController

GET Index

Endpoint to retrieve all the allowed Profiles for a specific Poi.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/pois/1/allowed-profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/pois/1/allowed-profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 4100,
            "attributes": {
                "created_at": "2020-02-06T12:54:57+00:00",
                "updated_at": "2020-02-06T12:54:57+00:00",
                "deleted_at": null,
                "tags": [],
                "category": "chipcard_product_profile",
                "link_id": 8380,
                "properties": []
            },
            "relationships": {
                "options": {
                    "data": [
                        {
                            "id": 2119,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2120,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2121,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2122,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        }
                    ]
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/4100"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/profiles?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/profiles?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/pois/{poi}/allowed-profiles

Poi Profiles Requests

API Calls (v2) for fetching and managing the Profiles for a specific Poi.

Class PoiProfilesController

GET Index

Endpoint to retrieve all the Profiles (via api_entity_profiles) for a specific Poi.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/pois/1/profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/pois/1/profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 4100,
            "attributes": {
                "created_at": "2020-02-06T12:54:57+00:00",
                "updated_at": "2020-02-06T12:54:57+00:00",
                "deleted_at": null,
                "tags": [],
                "category": "chipcard_product_profile",
                "link_id": 8380,
                "properties": []
            },
            "relationships": {
                "options": {
                    "data": [
                        {
                            "id": 2119,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2120,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2121,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2122,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        }
                    ]
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/4100"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/profiles?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/profiles?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/pois/{poi}/profiles

PoiRelatedPois Poi requests

API calls for managing Poi Related Pois Poi

GET PoiRelatedPoisPoi


Requires authentication returns a specific Poi Related Pois Poi

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1/poi" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1/poi");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "poi",
        "id": 1,
        "attributes": {
            "created_at": "2019-08-24T10:29:35+00:00",
            "updated_at": "2019-08-24T10:29:35+00:00",
            "deleted_at": null,
            "tags": [],
            "street": "Teststraat",
            "city": "Aalst",
            "country": "België",
            "link_id": null,
            "category": "residential_poi",
            "number": 1,
            "letter": null,
            "addition": null,
            "zipcode": "9300",
            "position": null
        },
        "relationships": {
            "street": {
                "data": {
                    "type": "geo_location",
                    "id": 173
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/streets"
                }
            },
            "city": {
                "data": {
                    "type": "geo_location",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/cities"
                }
            },
            "country": {
                "data": {
                    "type": "geo_location",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/countries"
                }
            },
            "products": {
                "data": [
                    {
                        "type": "product",
                        "id": 5
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/products"
                }
            },
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 6
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/customer"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/poi-related-pois/{poiRelatedPois}/poi

PoiRelatedPois RelatedPoi requests

API calls for managing Poi Related Pois RelatedPoi

GET PoiRelatedPoisRelatedPoi


Requires authentication returns a specific Poi Related Pois RelatedPoi

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1/related-poi" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1/related-poi");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "poi",
        "id": 1,
        "attributes": {
            "created_at": "2016-03-07T14:01:38+00:00",
            "updated_at": "2016-03-07T14:01:38+00:00",
            "deleted_at": null,
            "tags": [],
            "street": "Teststraat",
            "city": "Aalst",
            "country": "België",
            "link_id": null,
            "category": "ciaccess_poi",
            "number": 23,
            "letter": null,
            "addition": null,
            "zipcode": "2660",
            "position": {
                "lat": 0,
                "lon": 0
            }
        },
        "relationships": {
            "street": {
                "data": {
                    "type": "geo_location",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/streets"
                }
            },
            "city": {
                "data": {
                    "type": "geo_location",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/cities"
                }
            },
            "country": {
                "data": {
                    "type": "geo_location",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/countries"
                }
            },
            "products": {
                "data": [
                    {
                        "type": "product",
                        "id": 1
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/products"
                }
            },
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1\/customer"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/poi-related-pois/{poiRelatedPois}/related-poi

PoiRelatedPois requests

API calls for managing Poi Related Pois

Available Repeat types:

Name Description
yearly
monthly
weekly
daily

GET PoiRelatedPois


Requires authentication returns a list with PoiRelatedPois

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 2,
            "total": 2,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "poi-related-poi",
            "id": 1,
            "attributes": {
                "created_at": "2019-08-26T06:28:08+00:00",
                "updated_at": "2019-08-26T06:28:08+00:00",
                "deleted_at": null,
                "from": "2019-08-23T10:03:11+00:00",
                "until": null,
                "repeat": "weekly",
                "category": "collect_poi"
            },
            "relationships": {
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi\/1\/poi"
                    }
                },
                "related-poi": {
                    "data": {
                        "type": "poi-related-poi",
                        "id": 2
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois\/1\/related-poi"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois?page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.category": [
            "The selected filter.category is invalid."
        ],
        "data.attributes.related_poi_category": [
            "The selected filter.related_poi_category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/poi-related-pois

Query Parameters

Parameter Status Description
filter[poi] optional Search on specific Poi id.
filter[category] optional Search on specific category id. Should be a Poi category.
filter[related_poi] optional Search on specific related Poi id.
filter[related_poi_category] optional Search on specific category from related Poi.
filter[from] optional Search on specific from date.
filter[from_min] optional Search on min from date.
filter[from_max] optional Search on max from date.
filter[from_between] optional Search from between two dates (inclusive).
filter[until] optional Search on specific until date.
filter[until_min] optional Search on min until date.
filter[until_max] optional Search on max until date.
filter[until_between] optional Search until between two dates (inclusive).
filter[on_date] optional Search on specific date.

GET a PoiRelatedPois


Requires authentication returns a single PoiRelatedPois

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "poi-related-poi",
        "id": 1,
        "attributes": {
            "created_at": "2019-08-26T06:28:08+00:00",
            "updated_at": "2019-08-26T06:28:08+00:00",
            "deleted_at": null,
            "from": "2019-08-23T10:03:11+00:00",
            "until": null,
            "repeat": "weekly",
            "category": "collect_poi"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi\/1\/poi"
                }
            },
            "related-poi": {
                "data": {
                    "type": "poi-related-poi",
                    "id": 2
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois\/1\/related-poi"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois\/1"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/poi-related-pois/{poiRelatedPois}

POST PoiRelatedPois


Requires authentication Creates a specific PoiRelatedPois

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"poi-related-poi","attributes":{"from":"2019-08-23T12:27:19+00:00","until":"2019-08-23T12:27:19+00:00","repeat":"monthly","category":"collect_poi"},"relationships":{"poi":{"data":{"id":2}},"related-poi":{"data":{"id":"2"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "poi-related-poi",
        "attributes": {
            "from": "2019-08-23T12:27:19+00:00",
            "until": "2019-08-23T12:27:19+00:00",
            "repeat": "monthly",
            "category": "collect_poi"
        },
        "relationships": {
            "poi": {
                "data": {
                    "id": 2
                }
            },
            "related-poi": {
                "data": {
                    "id": "2"
                }
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "poi-related-poi",
        "id": 191,
        "attributes": {
            "created_at": "2019-08-23T12:27:19+00:00",
            "updated_at": "2019-08-23T12:27:19+00:00",
            "deleted_at": null,
            "from": "2019-08-22T12:08:16+00:00",
            "until": null,
            "repeat": "monthly",
            "category": "collect_poi"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 21
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi\/191\/poi"
                }
            },
            "related-poi": {
                "data": {
                    "type": "poi-related-poi",
                    "id": 12
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois\/191\/related-poi"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois\/191"
        }
    },
    "links": []
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.api_poi_id": [
            "The data.attributes.api poi id field is required."
        ],
        "data.attributes.api_related_poi_id": [
            "The data.attributes.api related poi id field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.repeat": [
            "The selected data.attributes.repeat is invalid."
        ]
    }
}

HTTP Request

POST api/v1/poi-related-pois

Body Parameters

Parameter Type Status Description
data.type string required type.
data.attributes.from string required From date.
data.attributes.until string optional optional Until date.
data.attributes.repeat string optional optional should be a repeat_type as mentioned at the top of this page.
data.attributes.category string required should be a poi category.
data.relationships.poi.data.id integer required Poi id.
data.relationships.related-poi.data.id string required Poi id.

PATCH PoiRelatedPois


Requires authentication Updates a specific PoiRelatedPois

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"poi-related-poi","attributes":{"from":"2019-08-23T12:27:19+00:00","until":"2019-08-23T12:27:19+00:00","repeat":"monthly","category":"collect_poi"},"relationships":{"poi":{"data":{"id":2}},"related-poi":{"data":{"id":"2"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "poi-related-poi",
        "attributes": {
            "from": "2019-08-23T12:27:19+00:00",
            "until": "2019-08-23T12:27:19+00:00",
            "repeat": "monthly",
            "category": "collect_poi"
        },
        "relationships": {
            "poi": {
                "data": {
                    "id": 2
                }
            },
            "related-poi": {
                "data": {
                    "id": "2"
                }
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "poi-related-poi",
        "id": 191,
        "attributes": {
            "created_at": "2019-08-23T12:27:19+00:00",
            "updated_at": "2019-08-23T12:27:19+00:00",
            "deleted_at": null,
            "from": "2019-08-22T12:08:16+00:00",
            "until": null,
            "repeat": "monthly",
            "category": "collect_poi"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 21
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi\/191\/poi"
                }
            },
            "related-poi": {
                "data": {
                    "type": "poi-related-poi",
                    "id": 12
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois\/191\/related-poi"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/poi-related-pois\/191"
        }
    },
    "links": []
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.api_poi_id": [
            "The data.attributes.api poi id field is required."
        ],
        "data.attributes.api_related_poi_id": [
            "The data.attributes.api related poi id field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ],
        "data.attributes.repeat": [
            "The selected data.attributes.repeat is invalid."
        ],
        "data.attributes.category": [
            "The selected filter.category is invalid."
        ]
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

PATCH api/v1/poi-related-pois/{poiRelatedPois}

Body Parameters

Parameter Type Status Description
data.type string optional optional type.
data.attributes.from string required From date.
data.attributes.until string optional optional Until date.
data.attributes.repeat string optional optional should be a repeat_type as mentioned at the top of this page.
data.attributes.category string optional optional should be a poi category.
data.relationships.poi.data.id integer optional optional Poi id.
data.relationships.related-poi.data.id string optional optional Poi id.

DELETE PoiRelatedPois

Endpoint to delete a specific PoiRelatedPois.


Requires authentication

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/poi-related-pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v1/poi-related-pois/{poiRelatedPois}

Poi Requests

API calls for managing Pois

Available categories:

Name Description
ciaccess_poi
collect_poi
collective_poi
deliver_poi
event_poi
invoice_poi
residential_poi
send_invoice_to_poi

GET Poi from Customer


Requires authentication returns pois linked to a specific customer

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/customers/1/pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 10000,
            "last_page": 100
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "poi",
            "id": 1517,
            "attributes": {
                "created_at": "2019-07-09T14:48:43+00:00",
                "updated_at": "2019-07-09T14:48:43+00:00",
                "deleted_at": null,
                "tags": [],
                "street": "Altenaken",
                "city": "Hoegaarden",
                "country": "België",
                "link_id": null,
                "category": "residential_poi",
                "number": 31,
                "letter": null,
                "addition": null,
                "zipcode": "3320",
                "position": null
            },
            "relationships": {
                "street": {
                    "data": {
                        "type": "geo_location",
                        "id": 70
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/streets"
                    }
                },
                "city": {
                    "data": {
                        "type": "geo_location",
                        "id": 5
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/cities"
                    }
                },
                "country": {
                    "data": {
                        "type": "geo_location",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/countries"
                    }
                },
                "events": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/events"
                    }
                },
                "products": {
                    "data": [
                        {
                            "type": "product",
                            "id": 1502
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/products"
                    }
                },
                "profiles": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 2773
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/profiles"
                    }
                },
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/customer"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois?page[number]=100"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/customers/{customer}/pois

Get Poi from Event


Requires authentication returns pois linked to a specific event

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/events/1/pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/events/1/pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "poi",
        "id": 19600,
        "attributes": {
            "created_at": "2019-07-09T14:51:30+00:00",
            "updated_at": "2018-05-17T09:01:51+00:00",
            "deleted_at": null,
            "tags": [],
            "street": "Brouwerij Loriersstraat",
            "city": "Hoegaarden",
            "country": "België",
            "link_id": null,
            "category": "residential_poi",
            "number": 35,
            "letter": "",
            "addition": "",
            "zipcode": "3320",
            "position": {
                "lat": 50.780649,
                "lon": 4.868568
            }
        },
        "relationships": {
            "street": {
                "data": {
                    "type": "geo_location",
                    "id": 76
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19600\/streets"
                }
            },
            "city": {
                "data": {
                    "type": "geo_location",
                    "id": 5
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19600\/cities"
                }
            },
            "country": {
                "data": {
                    "type": "geo_location",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19600\/countries"
                }
            },
            "events": {
                "data": [
                    {
                        "type": "event",
                        "id": 11
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19600\/events"
                }
            },
            "products": {
                "data": [
                    {
                        "type": "product",
                        "id": 19622
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19600\/products"
                }
            },
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": 2820
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19600\/profiles"
                }
            },
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 6
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19600\/customer"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19600"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/events/{event}/pois

GET Poi from Person poi history


Requires authentication returns a single poi linked to a specific person-poi-history

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history/1/poi" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/person-poi-history/1/poi");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "poi",
        "id": 17,
        "attributes": {
            "created_at": "2019-07-09T14:48:27+00:00",
            "updated_at": "2019-07-09T14:48:27+00:00",
            "deleted_at": null,
            "tags": [],
            "street": "Hoeksen",
            "city": "Hoegaarden",
            "country": "België",
            "link_id": null,
            "category": "residential_poi",
            "number": 1,
            "letter": null,
            "addition": null,
            "zipcode": "3320",
            "position": null
        },
        "relationships": {
            "street": {
                "data": {
                    "type": "geo_location",
                    "id": 92
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/streets"
                }
            },
            "city": {
                "data": {
                    "type": "geo_location",
                    "id": 5
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/cities"
                }
            },
            "country": {
                "data": {
                    "type": "geo_location",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/countries"
                }
            },
            "events": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/events"
                }
            },
            "products": {
                "data": [
                    {
                        "type": "product",
                        "id": 1
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/products"
                }
            },
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": 2773
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/profiles"
                }
            },
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 6
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17\/customer"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/17"
        }
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/person-poi-history/{personPoiHistory}/poi

GET Pois from Person


Requires authentication returns a pois linked to a specific person

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/persons/1/pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/persons/1/pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "current_page": 1,
    "data": [
        {
            "id": 7525,
            "category": "residential_poi",
            "zipcode": "9300",
            "number": 40,
            "letter": null,
            "addition": null,
            "latitude": null,
            "longitude": null,
            "properties": null,
            "external_id": null,
            "link_id": 24069,
            "api_customer_id": 6,
            "api_geo_location_id": 169,
            "poi": {
                "id": 24069,
                "project_id": 6,
                "zipcode": "9300",
                "zip_extension": null,
                "number": 40,
                "extension1": null,
                "extension2": null,
                "extension3": null,
                "extern_id": "16756",
                "object_nr": null,
                "memo1": null,
                "memo2": null,
                "memo3": null,
                "intervention_info": null,
                "longitude": null,
                "latitude": null,
                "original": true,
                "meta": null,
                "inhabitant_id": 24069,
                "inhabitant_main_category_id": 42,
                "inhabitant_sub_category_id": 382,
                "inhabitant_since": "2016-01-01 00:00:00",
                "bag_id": null,
                "woz_id": null,
                "other_garbage_info": null
            }
        }
    ],
    "first_page_url": "\/?page=1",
    "from": 1,
    "last_page": 1,
    "last_page_url": "\/?page=1",
    "next_page_url": null,
    "path": "\/",
    "per_page": 1,
    "prev_page_url": null,
    "to": 1,
    "total": 1
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/persons/{person}/pois

POST POI


Requires authentication creates a specific poi

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"poi","attributes":{"category":"ciaccess_poi","zipcode":"Example calendar","number":"Example calendar","letter":"Example calendar","addition":"Example calendar","external_id":"Example calendar","latitude":"Example calendar","longitude":"Example calendar","properties":"Example calendar","tags":"Example calendar"},"relationships":{"geo_location":{"data":{"id":1,"type":"street_geo_location"}},"profiles":{"data":[{"id":2,"type":"api_profiles"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "poi",
        "attributes": {
            "category": "ciaccess_poi",
            "zipcode": "Example calendar",
            "number": "Example calendar",
            "letter": "Example calendar",
            "addition": "Example calendar",
            "external_id": "Example calendar",
            "latitude": "Example calendar",
            "longitude": "Example calendar",
            "properties": "Example calendar",
            "tags": "Example calendar"
        },
        "relationships": {
            "geo_location": {
                "data": {
                    "id": 1,
                    "type": "street_geo_location"
                }
            },
            "profiles": {
                "data": [
                    {
                        "id": 2,
                        "type": "api_profiles"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 10000,
            "last_page": 100
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "poi",
            "id": 1517,
            "attributes": {
                "created_at": "2019-07-09T14:48:43+00:00",
                "updated_at": "2019-07-09T14:48:43+00:00",
                "deleted_at": null,
                "tags": [],
                "street": "Altenaken",
                "city": "Hoegaarden",
                "country": "België",
                "link_id": null,
                "category": "residential_poi",
                "number": 31,
                "letter": null,
                "addition": null,
                "zipcode": "3320",
                "position": null
            },
            "relationships": {
                "street": {
                    "data": {
                        "type": "geo_location",
                        "id": 70
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/streets"
                    }
                },
                "city": {
                    "data": {
                        "type": "geo_location",
                        "id": 5
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/cities"
                    }
                },
                "country": {
                    "data": {
                        "type": "geo_location",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/countries"
                    }
                },
                "events": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/events"
                    }
                },
                "products": {
                    "data": [
                        {
                            "type": "product",
                            "id": 1502
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/products"
                    }
                },
                "profiles": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 2773
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/profiles"
                    }
                },
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/customer"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois?page[number]=100"
    }
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ]
    }
}

HTTP Request

POST api/v1/pois

Body Parameters

Parameter Type Status Description
data.type string required Type must be poi.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.zipcode string optional optional Zipcode of this Poi.
data.attributes.number string optional optional Number of this Poi.
data.attributes.letter string optional optional Letter of this Poi.
data.attributes.addition string optional optional Addition of this Poi.
data.attributes.external_id string optional optional Exernal Id of this Poi.
data.attributes.latitude string optional optional Latitude of this Poi.
data.attributes.longitude string optional optional Longitude of this Poi.
data.attributes.properties json optional optional Properties of this Poi.
data.attributes.tags array optional optional Tags of this Poi.
data.relationships.geo_location.data.id integer optional optional GeoLocation.
data.relationships.geo_location.data.type string optional optional Must be geo_location.
data.relationships.profiles.data.*.id integer optional optional Profile id.
data.relationships.profiles.data.*.type string optional optional Profile type must be profile.

PATCH Poi


Requires authentication updates a specific poi

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"poi","id":1,"attributes":{"category":"ciaccess_poi","zipcode":"Example calendar","number":"Example calendar","letter":"Example calendar","addition":"Example calendar","external_id":"Example calendar","latitude":"Example calendar","longitude":"Example calendar","properties":"Example calendar","tags":"Example calendar"},"relationships":{"geo_location":{"data":{"id":1,"type":"geo_location"}},"profile":{"data":[{"id":2,"type":"api_profiles"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "poi",
        "id": 1,
        "attributes": {
            "category": "ciaccess_poi",
            "zipcode": "Example calendar",
            "number": "Example calendar",
            "letter": "Example calendar",
            "addition": "Example calendar",
            "external_id": "Example calendar",
            "latitude": "Example calendar",
            "longitude": "Example calendar",
            "properties": "Example calendar",
            "tags": "Example calendar"
        },
        "relationships": {
            "geo_location": {
                "data": {
                    "id": 1,
                    "type": "geo_location"
                }
            },
            "profile": {
                "data": [
                    {
                        "id": 2,
                        "type": "api_profiles"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 10000,
            "last_page": 100
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "poi",
            "id": 1517,
            "attributes": {
                "created_at": "2019-07-09T14:48:43+00:00",
                "updated_at": "2019-07-09T14:48:43+00:00",
                "deleted_at": null,
                "tags": [],
                "street": "Altenaken",
                "city": "Hoegaarden",
                "country": "België",
                "link_id": null,
                "category": "residential_poi",
                "number": 31,
                "letter": null,
                "addition": null,
                "zipcode": "3320",
                "position": null
            },
            "relationships": {
                "street": {
                    "data": {
                        "type": "geo_location",
                        "id": 70
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/streets"
                    }
                },
                "city": {
                    "data": {
                        "type": "geo_location",
                        "id": 5
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/cities"
                    }
                },
                "country": {
                    "data": {
                        "type": "geo_location",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/countries"
                    }
                },
                "events": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/events"
                    }
                },
                "products": {
                    "data": [
                        {
                            "type": "product",
                            "id": 1502
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/products"
                    }
                },
                "profiles": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 2773
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/profiles"
                    }
                },
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517\/customer"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/1517"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6\/pois?page[number]=100"
    }
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ]
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

PATCH api/v1/pois/{poi}

Body Parameters

Parameter Type Status Description
data.type string optional optional Type must be poi.
data.id integer required The id must match the url id.
data.attributes.category string optional optional One of the categories mentioned at the top of this page.
data.attributes.zipcode string optional optional Zipcode of this Poi.
data.attributes.number string optional optional Number of this Poi.
data.attributes.letter string optional optional Letter of this Poi.
data.attributes.addition string optional optional Addition of this Poi.
data.attributes.external_id string optional optional Exernal Id of this Poi.
data.attributes.latitude string optional optional Latitude of this Poi.
data.attributes.longitude string optional optional Longitude of this Poi.
data.attributes.properties json optional optional Properties of this Poi.
data.attributes.tags array optional optional Tags of this Poi.
data.relationships.geo_location.data.id integer optional optional GeoLocation.
data.relationships.geo_location.data.type string optional optional Must be geo_location.
data.relationships.profile.data.*.id integer optional optional Profile id.
data.relationships.profile.data.*.type string optional optional Profile type must be profile.

PATCH Poi / Poi related pois properties


Requires authentication

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/properties" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"poi_id":1,"category":"collect_poi","poi_related_pois":{"id":0},"attributes":{"properties":"{\"memo\":\"\",\"access\":{\"memo\":\"\",\"code\":\"\"}}"}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/properties");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "poi_id": 1,
        "category": "collect_poi",
        "poi_related_pois": {
            "id": 0
        },
        "attributes": {
            "properties": "{\"memo\":\"\",\"access\":{\"memo\":\"\",\"code\":\"\"}}"
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "poi",
        "id": 27677,
        "attributes": {
            "created_at": "2019-10-16T11:36:48+00:00",
            "updated_at": "2019-10-16T11:36:48+00:00",
            "deleted_at": null,
            "tags": [],
            "street": "Verenigd Koninkrijk",
            "city": "Verenigd Koninkrijk",
            "country": "Verenigd Koninkrijk",
            "category": "collect_poi",
            "properties": {
                "woz_id": 765513,
                "collect_poi": {
                    "memo": "example memo",
                    "access": {
                        "code": "example code"
                    }
                }
            },
            "number": null,
            "letter": null,
            "addition": null,
            "zipcode": "",
            "position": null,
            "person_count": 0,
            "poi_related_pois.id": 982
        },
        "relationships": {
            "street": {
                "data": {
                    "type": "geo_location",
                    "id": 84136
                },
                "links": {
                    "related": "http:\/\/api.ci-web.eu\/api\/v1\/pois\/27677\/streets"
                }
            },
            "city": {
                "data": {
                    "type": "geo_location",
                    "id": 84135
                },
                "links": {
                    "related": "http:\/\/api.ci-web.eu\/api\/v1\/pois\/27677\/cities"
                }
            },
            "country": {
                "data": {
                    "type": "geo_location",
                    "id": 84134
                },
                "links": {
                    "related": "http:\/\/api.ci-web.eu\/api\/v1\/pois\/27677\/countries"
                }
            },
            "events": {
                "data": [],
                "links": {
                    "related": "http:\/\/api.ci-web.eu\/api\/v1\/pois\/27677\/events"
                }
            },
            "products": {
                "data": [],
                "links": {
                    "related": "http:\/\/api.ci-web.eu\/api\/v1\/pois\/27677\/products"
                }
            },
            "profiles": {
                "data": [],
                "links": {
                    "related": "http:\/\/api.ci-web.eu\/api\/v1\/pois\/27677\/profiles"
                }
            },
            "customer": {
                "data": {
                    "type": "customer",
                    "id": null
                },
                "links": {
                    "related": "http:\/\/api.ci-web.eu\/api\/v1\/pois\/27677\/customer"
                }
            },
            "related-pois": {
                "links": {
                    "related": "http:\/\/api.ci-web.eu\/api\/v1\/pois\/27677\/related-pois?filter[category]=ciaccess_poi,collect_poi,collective_poi,deliver_poi,event_poi,invoice_poi,residential_poi,send_invoice_to_poi"
                }
            }
        },
        "links": {
            "self": "http:\/\/api.ci-web.eu\/api\/v1\/pois\/27677"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.poi_id": [
            "The data.poi id field is required.",
            "The selected data.poi id is invalid.",
            "id mismatch, data.poi id value is not the same as in the link."
        ],
        "data.poi_related_pois.id": [
            "The selected data.poi related pois.id is invalid."
        ],
        "data.category": [
            "The data.category field is required.",
            "The selected data.category is invalid."
        ],
        "data.attributes.properties": [
            "The data.attributes.properties must be a valid JSON string."
        ]
    }
}

HTTP Request

PATCH api/v1/pois/{poi}/properties

Body Parameters

Parameter Type Status Description
data.poi_id integer required The id must match the url id.
data.category string required Must exist in the array of supported Poi categories.
data.poi_related_pois.id integer optional The optional id of the specific poi_related_pois record.
data.attributes.properties json optional The actual properties that need to be updated.

Returns POI based on checks in api_poi_related_pois,

based on the POI category and / or time.


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/related-pois? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/related-pois");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 2,
            "total": 2,
            "last_page": 1
        }
    },
    "errors": null,
    "data": [
        {
            "type": "poi",
            "id": 221,
            "attributes": {
                "created_at": "2019-10-07T19:39:20+00:00",
                "updated_at": "2019-10-07T19:39:20+00:00",
                "deleted_at": null,
                "tags": [],
                "street": "Verenigd Koninkrijk",
                "city": "Verenigd Koninkrijk",
                "country": "Verenigd Koninkrijk",
                "category": "collect_poi",
                "properties": {
                    "woz_id": 553432
                },
                "poi_related_pois.id": 180,
                "number": null,
                "letter": null,
                "addition": null,
                "zipcode": "",
                "position": null,
                "person_count": 0
            },
            "relationships": {
                "street": {
                    "data": {
                        "type": "geo_location",
                        "id": 544
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/221\/streets"
                    }
                },
                "city": {
                    "data": {
                        "type": "geo_location",
                        "id": 543
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/221\/cities"
                    }
                },
                "country": {
                    "data": {
                        "type": "geo_location",
                        "id": 542
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/221\/countries"
                    }
                },
                "events": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/221\/events"
                    }
                },
                "products": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/221\/products"
                    }
                },
                "profiles": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/221\/profiles"
                    }
                },
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": null
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/221\/customer"
                    }
                },
                "related-pois": {
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/221\/related-pois?filter[category]=ciaccess_poi,collect_poi,collective_poi,deliver_poi,event_poi,invoice_poi,residential_poi,send_invoice_to_poi"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/221"
            }
        },
        {
            "type": "poi",
            "id": 222,
            "attributes": {
                "created_at": "2019-10-07T19:39:20+00:00",
                "updated_at": "2019-10-07T19:39:20+00:00",
                "deleted_at": null,
                "tags": [],
                "street": "Verenigd Koninkrijk",
                "city": "Verenigd Koninkrijk",
                "country": "Verenigd Koninkrijk",
                "category": "ciaccess_poi",
                "properties": {
                    "woz_id": 538420
                },
                "poi_related_pois.id": null,
                "number": null,
                "letter": null,
                "addition": null,
                "zipcode": "",
                "position": null,
                "person_count": 0
            },
            "relationships": {
                "street": {
                    "data": {
                        "type": "geo_location",
                        "id": 547
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/streets"
                    }
                },
                "city": {
                    "data": {
                        "type": "geo_location",
                        "id": 546
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/cities"
                    }
                },
                "country": {
                    "data": {
                        "type": "geo_location",
                        "id": 545
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/countries"
                    }
                },
                "events": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/events"
                    }
                },
                "products": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/products"
                    }
                },
                "profiles": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/profiles"
                    }
                },
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": null
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/customer"
                    }
                },
                "related-pois": {
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/related-pois?filter[category]=ciaccess_poi,collect_poi,collective_poi,deliver_poi,event_poi,invoice_poi,residential_poi,send_invoice_to_poi"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/related-pois?filter[category]=collect_poi%2Cciaccess_poi",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/related-pois?filter[category]=collect_poi%2Cciaccess_poi&page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/222\/related-pois?filter[category]=collect_poi%2Cciaccess_poi&page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "filter.category": [
            "The selected filter.category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/pois/{poi}/related-pois

Query Parameters

Parameter Status Description
filter[category] optional Filter specific POI category.

GET nearest-pois


Requires authentication Returns pois nearest to location

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/nearest-pois? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/nearest-pois");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 10000,
            "last_page": 100
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "poi",
            "id": 19,
            "attributes": {
                "created_at": "2019-07-09T14:48:27+00:00",
                "updated_at": "2019-07-09T14:48:27+00:00",
                "deleted_at": null,
                "tags": [],
                "street": "Teststraat",
                "city": "Antwerpen",
                "country": "België",
                "link_id": null,
                "category": "residential_poi",
                "number": 999,
                "letter": null,
                "addition": null,
                "zipcode": "8790",
                "position": null
            },
            "relationships": {
                "street": {
                    "data": {
                        "type": "geo_location",
                        "id": 52
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/streets"
                    }
                },
                "city": {
                    "data": {
                        "type": "geo_location",
                        "id": 4
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/cities"
                    }
                },
                "country": {
                    "data": {
                        "type": "geo_location",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/countries"
                    }
                },
                "events": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/events"
                    }
                },
                "products": {
                    "data": [
                        {
                            "type": "product",
                            "id": 3
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/products"
                    }
                },
                "profiles": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 2773
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/profiles"
                    }
                },
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/customer"
                    }
                },
                "related-pois": {
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/related-pois?filter[category]=ciaccess_poi,collect_poi,collective_poi,deliver_poi,event_poi,invoice_poi,residential_poi,send_invoice_to_poi"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/pois?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois?page[number]=100"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/nearest-pois

Query Parameters

Parameter Status Description
filter[location] optional Pois nearest to the given location.

GET Index


Requires authentication Endpoint to retrieve all the BillingInformation entities for a specific Poi entity

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/billing-information" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/billing-information");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 4,
            "total": 4,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "billing-information",
            "id": 259,
            "attributes": {
                "created_at": "2020-05-19 04:17:45",
                "updated_at": "2020-05-19 04:17:45",
                "deleted_at": null,
                "id": 259,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": {
                "status": {
                    "data": {
                        "id": 8152,
                        "type": "option",
                        "attributes": {
                            "category": "status_billing_information",
                            "name": "Non facturable (en lieu de taxes)",
                            "parent_id": null,
                            "link_id": 7318
                        }
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/259\/status"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/259"
            }
        },
        {
            "type": "billing-information",
            "id": 260,
            "attributes": {
                "created_at": "2020-05-19 04:17:45",
                "updated_at": "2020-05-19 04:17:45",
                "deleted_at": null,
                "id": 260,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": {
                "status": {
                    "data": {
                        "id": 8153,
                        "type": "option",
                        "attributes": {
                            "category": "status_billing_information",
                            "name": "Non facturable (à la valeur)",
                            "parent_id": null,
                            "link_id": 7319
                        }
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/260\/status"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/260"
            }
        },
        {
            "type": "billing-information",
            "id": 261,
            "attributes": {
                "created_at": "2020-05-19 04:17:45",
                "updated_at": "2020-05-19 04:17:45",
                "deleted_at": null,
                "id": 261,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": {
                "status": {
                    "data": {
                        "id": 8154,
                        "type": "option",
                        "attributes": {
                            "category": "status_billing_information",
                            "name": "Non facturable (en lieu de taxes)",
                            "parent_id": null,
                            "link_id": 7320
                        }
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/261\/status"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/261"
            }
        },
        {
            "type": "billing-information",
            "id": 262,
            "attributes": {
                "created_at": "2020-05-19 04:17:45",
                "updated_at": "2020-05-19 04:17:45",
                "deleted_at": null,
                "id": 262,
                "from": null,
                "until": null,
                "properties": []
            },
            "relationships": {
                "status": {
                    "data": {
                        "id": 8155,
                        "type": "option",
                        "attributes": {
                            "category": "status_billing_information",
                            "name": "Non facturable (en lieu de taxes)",
                            "parent_id": null,
                            "link_id": 7321
                        }
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information\/262\/status"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-informations\/262"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/billing-information?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/pois/{poi}/billing-information

GET Poi from Product


Requires authentication returns pois linked to a specific product

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/products/1/pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/products/1/pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "poi",
            "id": 30,
            "attributes": {
                "created_at": "2019-07-09T14:48:27+00:00",
                "updated_at": "2019-07-09T14:48:27+00:00",
                "deleted_at": null,
                "tags": [],
                "street": "Vennestraat",
                "city": "Antwerpen",
                "country": "België",
                "link_id": null,
                "category": "residential_poi",
                "number": 44,
                "letter": null,
                "addition": null,
                "zipcode": "8790",
                "position": null
            },
            "relationships": {
                "street": {
                    "data": {
                        "type": "geo_location",
                        "id": 60
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/30\/streets"
                    }
                },
                "city": {
                    "data": {
                        "type": "geo_location",
                        "id": 4
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/30\/cities"
                    }
                },
                "country": {
                    "data": {
                        "type": "geo_location",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/30\/countries"
                    }
                },
                "events": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/30\/events"
                    }
                },
                "products": {
                    "data": [
                        {
                            "type": "product",
                            "id": 14
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/30\/products"
                    }
                },
                "profiles": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 2773
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/30\/profiles"
                    }
                },
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/30\/customer"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/30"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/pois",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/pois?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/pois?page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/products/{product}/pois

Pois

API calls for managing Pois

GET Poi's from Calendar


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 7,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "poi",
            "id": 20,
            "attributes": {
                "created_at": "2019-06-27T09:52:32+00:00",
                "updated_at": "2019-06-27T09:52:32+00:00",
                "deleted_at": null,
                "tags": [],
                "street": "Hoeksen",
                "city": "Hoegaarden",
                "country": "België",
                "link_id": null,
                "category": "residential_poi",
                "number": 1,
                "letter": null,
                "addition": null,
                "zipcode": "3320",
                "position": null
            },
            "relationships": {
                "street": {
                    "data": {
                        "type": "geo_location",
                        "id": 99
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/20\/streets"
                    }
                },
                "city": {
                    "data": {
                        "type": "geo_location",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/20\/cities"
                    }
                },
                "country": {
                    "data": {
                        "type": "geo_location",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/20\/countries"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": 8269
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/20\/events"
                    }
                },
                "products": {
                    "data": [
                        {
                            "type": "product",
                            "id": 1
                        },
                        {
                            "type": "product",
                            "id": 2
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/20\/products"
                    }
                },
                "profiles": {
                    "data": [
                        {
                            "type": "profile",
                            "id": 2347
                        },
                        {
                            "type": "profile",
                            "id": 2348
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/20\/profiles"
                    }
                },
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/20\/customers"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/20"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois?size=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois?size=1&page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois?size=1&page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/pois?size=1&page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/calendars/{calendar}/pois

ProductFieldHistory Requests

Class ProductFieldHistoryController

GET Product field histories


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/product-field-history? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-field-history");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 85315,
            "last_page": 854
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "product-field-history",
            "id": 1,
            "attributes": {
                "created_at": "2019-07-18T12:28:21+00:00",
                "updated_at": "2019-07-18T12:28:21+00:00",
                "deleted_at": null,
                "product_id": 502,
                "field_name": "barcode",
                "field_value": "017288",
                "from": "2019-07-18T12:28:21+00:00"
            },
            "relationships": {
                "product": {
                    "data": {
                        "type": "product",
                        "id": 502
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-field-history\/1\/product"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-field-histories\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-field-history",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/product-field-history?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/product-field-history?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/product-field-history?page[number]=854"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/product-field-history

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[product] optional Find field history from Product by id or ids.
filter[product_id] optional Find field history from Product by id or ids.
filter[field_name] optional Filter by the field name.
filter[field_value] optional Filter by the field value.
filter[on_date] optional options from a certain date.
filter[from] optional filter on given from date.
filter[from_min] optional filter having a from date greater than or equal to the given value.
filter[from_max] optional filter having a from date lesser than or equal to the given value..
filter[from_between] optional Filter from between two dates (inclusive).
filter[until] optional options until a certain date.
filter[until_min] optional filter having an until date greater than or equal to the given value.
filter[until_max] optional filter having an until date lesser than or equal to the given value.
filter[until_between] optional Filter until between two dates (inclusive).

POST Product field history


Requires authentication

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/product-field-history" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"option","attributes":{"field_name":"chip","field_value":"ABC00112233","from":"2019-01-01T00:00:00Z"},"relationships":{"product":{"data":{"id":123,"type":"product"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-field-history");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "option",
        "attributes": {
            "field_name": "chip",
            "field_value": "ABC00112233",
            "from": "2019-01-01T00:00:00Z"
        },
        "relationships": {
            "product": {
                "data": {
                    "id": 123,
                    "type": "product"
                }
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product-field-history",
        "id": 86490,
        "attributes": {
            "created_at": "2019-07-19T10:01:42+00:00",
            "updated_at": "2019-07-19T10:01:42+00:00",
            "deleted_at": null,
            "product_id": "1",
            "field_name": "barcode",
            "field_value": "foo-bar-22",
            "from": "2016-01-01T00:00:00+00:00"
        },
        "relationships": {
            "product": {
                "data": {
                    "type": "product",
                    "id": "1"
                },
                "links": {
                    "related": "api.ci-web.eu\/api\/api\/v1\/product-field-history\/86490\/product"
                }
            }
        },
        "links": {
            "self": "api.ci-web.eu\/api\/api\/v1\/product-field-histories\/86490"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.field_name": [
            "The data.attributes.field name field is required."
        ],
        "data.attributes.field_value": [
            "The data.attributes.field value field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ],
        "data.relationships.product.data": [
            "The data.relationships.product.data field is required."
        ],
        "data.relationships.product.data.type": [
            "The data.relationships.product.data.type field is required."
        ],
        "data.relationships.product.data.id": [
            "The data.relationships.product.data.id field is required."
        ]
    }
}

HTTP Request

POST api/v1/product-field-history

Body Parameters

Parameter Type Status Description
data.type string required Type must be option.
data.attributes.field_name string required Must be a valid ProductFieldHistory field name.
data.attributes.field_value string required Value of this field history record.
data.attributes.from Date required Date that activates the given field value .
data.relationships.product.data.id integer optional Required Product parent that the field history belongs to.
data.relationships.product.data.type string optional optional Must be product.

PATCH Product field history


Requires authentication

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/product-field-history/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"option","id":1,"attributes":{"field_name":"chip","field_value":"ABC00112233","from":"2019-01-01T00:00:00Z"},"relationships":{"product":{"data":{"id":123,"type":"product"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-field-history/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "option",
        "id": 1,
        "attributes": {
            "field_name": "chip",
            "field_value": "ABC00112233",
            "from": "2019-01-01T00:00:00Z"
        },
        "relationships": {
            "product": {
                "data": {
                    "id": 123,
                    "type": "product"
                }
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product-field-history",
        "id": 86490,
        "attributes": {
            "created_at": "2019-07-19T10:01:42+00:00",
            "updated_at": "2019-07-19T10:01:42+00:00",
            "deleted_at": null,
            "product_id": "1",
            "field_name": "barcode",
            "field_value": "foo-bar-22",
            "from": "2016-01-01T00:00:00+00:00"
        },
        "relationships": {
            "product": {
                "data": {
                    "type": "product",
                    "id": "1"
                },
                "links": {
                    "related": "api.ci-web.eu\/api\/api\/v1\/product-field-history\/86490\/product"
                }
            }
        },
        "links": {
            "self": "api.ci-web.eu\/api\/api\/v1\/product-field-histories\/86490"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.field_name": [
            "The data.attributes.field name field is required."
        ],
        "data.attributes.field_value": [
            "The data.attributes.field value field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from field is required."
        ],
        "data.relationships.product.data": [
            "The data.relationships.product.data field is required."
        ],
        "data.relationships.product.data.type": [
            "The data.relationships.product.data.type field is required."
        ],
        "data.relationships.product.data.id": [
            "The data.relationships.product.data.id field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/product-field-history/{productFieldHistory}

Body Parameters

Parameter Type Status Description
data.type string required Type must be option.
data.id integer required The id must match the url id.
data.attributes.field_name string optional Must be a valid ProductFieldHistory field name.
data.attributes.field_value string optional Value of this field history record.
data.attributes.from date optional Date that activates the given field value .
data.relationships.product.data.id integer optional Product parent that the field history belongs to.
data.relationships.product.data.type string optional Must be product.

GET a specific Product field history


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/product-field-history/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-field-history/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product-field-history",
        "id": 1,
        "attributes": {
            "created_at": "2019-07-18T12:28:21+00:00",
            "updated_at": "2019-07-18T12:28:21+00:00",
            "deleted_at": null,
            "product_id": 502,
            "field_name": "barcode",
            "field_value": "017288",
            "from": "2016-01-01T00:00:00+00:00"
        },
        "relationships": {
            "product": {
                "data": {
                    "type": "product",
                    "id": 502
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-field-history\/1\/product"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-field-histories\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/product-field-history/{productFieldHistory}

ProductRelatedPois Requests

API calls for managing ProductRelatedPois

Available repeat types:

Name Description
yearly
monthly
weekly
daily

GET Product Related Pois


Requires authentication returns all product-related-pois

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 49750,
            "last_page": 498
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "product-related-poi",
            "id": 1,
            "attributes": {
                "created_at": "2019-06-28T06:01:54+00:00",
                "updated_at": "2019-06-28T06:01:54+00:00",
                "deleted_at": null,
                "from": "2016-01-01T00:00:00+00:00",
                "until": null,
                "repeat": "weekly",
                "category": "collect_poi"
            },
            "relationships": {
                "product": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1\/products"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 17
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1\/pois"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois?page[number]=498"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/product-related-pois

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[poi_id] optional Filter on specific poi_id.
filter[from] optional Filter on from.
filter[from_min] optional Filter on from_min. 2018-05-05 12:34:56
filter[from_max] optional Filter on from_max. 2019-01-01 12:34:56
filter[from_between] optional Filter from between two dates (inclusive).
filter[product_id] optional Filter on product id.
filter[category] optional Filter on the product related pois category.
filter[poi_category] optional Filter on related Poi category.
filter[until_between] optional Filter until between two dates (inclusive).
filter[collector] optional Filter on Products that have Registrations with given Collector id.

POST Product Related Pois


Requires authentication creates a new Product Related Pois

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"product-related-pois","attributes":{"from":"2018-05-05 12:34:56","until":"2018-05-05 12:34:56","repeat":"weekly","category":"collect_poi"},"relationships":{"poi":{"data":{"type":"poi","id":1}},"product":{"data":{"type":"product","id":1}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "product-related-pois",
        "attributes": {
            "from": "2018-05-05 12:34:56",
            "until": "2018-05-05 12:34:56",
            "repeat": "weekly",
            "category": "collect_poi"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 1
                }
            },
            "product": {
                "data": {
                    "type": "product",
                    "id": 1
                }
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product-related-poi",
        "id": 70131,
        "attributes": {
            "created_at": "2019-07-09T08:42:47+00:00",
            "updated_at": "2019-07-09T08:42:47+00:00",
            "deleted_at": null,
            "from": "2016-01-01T00:00:00+00:00",
            "repeat": "weekly",
            "category": "collect_poi"
        },
        "relationships": {
            "product": {
                "data": {
                    "type": "product",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/70131\/products"
                }
            },
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/70131\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/70131"
        }
    },
    "links": []
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from date field is required."
        ],
        "data.attributes.repeat": [
            "The selected data.attributes.repeat is invalid."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required.",
            "The data.attributes.category field is invalid."
        ],
        "data.relationships.poi.data.type": [
            "The data.relationships.poi.data.type field is required."
        ],
        "data.relationships.poi.data.id": [
            "The data.relationships.poi.data.id field is required."
        ],
        "data.relationships.product.data.type": [
            "The data.relationships.product.data.type field is required."
        ],
        "data.relationships.product.data.id": [
            "The data.relationships.product.data.id field is required."
        ]
    }
}

HTTP Request

POST api/v1/product-related-pois

Body Parameters

Parameter Type Status Description
data.type string required Type must be product-related-pois.
data.attributes.from string required from.
data.attributes.until string optional optional until.
data.attributes.repeat string optional optional repeat. Must be one of the types mentioned at the top of this file.
data.attributes.category string optional required. Must be a POI category related value.
data.relationships.poi.data.type string required Type must be poi.
data.relationships.poi.data.id integer required poi id.
data.relationships.product.data.type string required Type must be product.
data.relationships.product.data.id integer required product id.

PATCH Product Related Pois


Requires authentication updates a specific Product Related Pois

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"product-related-pois","id":1,"attributes":{"from":"2018-05-05 12:34:56","until":"2018-05-05 12:34:56","repeat":"weekly","category":"collect_poi"},"relationships":{"poi":{"data":{"type":"poi","id":1}},"product":{"data":{"type":"product","id":1}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "product-related-pois",
        "id": 1,
        "attributes": {
            "from": "2018-05-05 12:34:56",
            "until": "2018-05-05 12:34:56",
            "repeat": "weekly",
            "category": "collect_poi"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 1
                }
            },
            "product": {
                "data": {
                    "type": "product",
                    "id": 1
                }
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product-related-poi",
        "id": 1,
        "attributes": {
            "created_at": "2019-06-28T06:01:54+00:00",
            "updated_at": "2019-07-09T08:52:44+00:00",
            "deleted_at": null,
            "from": "2016-01-01T00:00:00+00:00",
            "repeat": "weekly",
            "category": "collect_poi"
        },
        "relationships": {
            "product": {
                "data": {
                    "type": "product",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1\/products"
                }
            },
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 17
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1"
        }
    },
    "links": []
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.from": [
            "The data.attributes.from date field is required."
        ],
        "data.attributes.repeat": [
            "The selected data.attributes.repeat is invalid."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required.",
            "The data.attributes.category field is invalid."
        ],
        "data.relationships.poi.data.type": [
            "The data.relationships.poi.data.type field is required."
        ],
        "data.relationships.poi.data.id": [
            "The data.relationships.poi.data.id field is required."
        ],
        "data.relationships.product.data.type": [
            "The data.relationships.product.data.type field is required."
        ],
        "data.relationships.product.data.id": [
            "The data.relationships.product.data.id field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/product-related-pois/{productRelatedPois}

Body Parameters

Parameter Type Status Description
data.type string optional optional Type must be product-related-pois.
data.id integer optional optional The id must match the url id.
data.attributes.from string optional optional from.
data.attributes.until string optional optional until.
data.attributes.repeat string optional optional repeat. Must be one of the types mentioned at the top of this file.
data.attributes.category string optional required. Must be a POI category related value.
data.relationships.poi.data.type string optional optional Type must be poi.
data.relationships.poi.data.id integer optional optional poi id.
data.relationships.product.data.type string optional optional Type must be product.
data.relationships.product.data.id integer optional optional product id.

GET Product Related Pois


Requires authentication returns a single product-related-pois

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product-related-poi",
        "id": 1,
        "attributes": {
            "created_at": "2019-06-28T06:01:54+00:00",
            "updated_at": "2019-06-28T06:01:54+00:00",
            "deleted_at": null,
            "from": "2016-01-01T00:00:00+00:00",
            "until": null,
            "repeat": "weekly",
            "category": "collect_poi"
        },
        "relationships": {
            "product": {
                "data": {
                    "type": "product",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1\/products"
                }
            },
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 17
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/product-related-pois/{productRelatedPois}

DELETE Product Related Pois

Endpoint to delete a specific Product Related Pois.


Requires authentication

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-related-pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v1/product-related-pois/{productRelatedPois}

Product Requests

API calls for managing Products

Available categories:

Name Description
bin_product
group_bin_product
ciaccess_product
chipcard_product

GET Products


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/products? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/products");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 10000,
            "last_page": 100
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "product",
            "id": 14,
            "attributes": {
                "created_at": "2019-07-04T12:43:34+00:00",
                "updated_at": "2019-07-04T12:43:34+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "bin_product",
                "status": "active",
                "chipcode": "00004849116781",
                "barcode": "116781",
                "labelcode": null,
                "bincode": null,
                "description": "CONTAINER",
                "volume": "140",
                "fraction": "REST",
                "designation": "SLOT"
            },
            "relationships": {
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 30
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/pois"
                    }
                },
                "profile": {
                    "data": {
                        "type": "profile",
                        "id": 94
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/profiles"
                    }
                },
                "events": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/events"
                    }
                },
                "open_interruptions": {
                    "data": [
                        {
                            "type": "registration",
                            "id": 37424
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.dev\/api\/v1\/products\/47601\/open_interruptions"
                    }
                },
                "closed_interruptions": {
                    "data": [
                        {
                            "type": "registration",
                            "id": 37425
                        }
                    ],
                    "links": {
                        "related": "https:\/\/api.ci-web.dev\/api\/v1\/products\/47601\/open_interruptions"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/products",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/products?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/products?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/products?page[number]=100"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/products

Query Parameters

Parameter Status Description
filter[planned_collectors] optional Find Registrations with given Collector id.

GET product


Requires authentication returns a specific product

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/products/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/products/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product",
        "id": 14,
        "attributes": {
            "created_at": "2019-07-04T12:43:34+00:00",
            "updated_at": "2019-07-04T12:43:34+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "bin_product",
            "status": "active",
            "chipcode": "00004849116781",
            "barcode": "116781",
            "labelcode": null,
            "bincode": null,
            "description": "CONTAINER",
            "volume": "140",
            "fraction": "REST",
            "designation": "SLOT"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 30
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/pois"
                }
            },
            "profile": {
                "data": {
                    "type": "profile",
                    "id": 94
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/profiles"
                }
            },
            "events": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/events"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/products/{product}

GET Product from Event


Requires authentication returns the linked product from a specific event

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/events/1/product" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/events/1/product");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product",
        "id": 3,
        "attributes": {
            "created_at": "2019-07-09T15:11:55+00:00",
            "updated_at": "2019-07-09T15:11:55+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "bin_product",
            "status": "active",
            "chipcode": "00004849050582",
            "barcode": "050582",
            "labelcode": null,
            "bincode": null,
            "description": "CONTAINER",
            "volume": "240",
            "fraction": "REST",
            "designation": "STANDAARD"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 19
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/3\/pois"
                }
            },
            "profile": {
                "data": {
                    "type": "profile",
                    "id": 90
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/3\/profiles"
                }
            },
            "events": {
                "data": [
                    {
                        "type": "event",
                        "id": 1
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/3\/events"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/product\/3"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/events/{event}/product

GET Deliver Product from Event


Requires authentication returns the delivered product from a specific event

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/events/1/deliver-product" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/events/1/deliver-product");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product",
        "id": 3,
        "attributes": {
            "created_at": "2019-07-09T15:11:55+00:00",
            "updated_at": "2019-07-09T15:11:55+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "bin_product",
            "status": "active",
            "chipcode": "00004849050582",
            "barcode": "050582",
            "labelcode": null,
            "bincode": null,
            "description": "CONTAINER",
            "volume": "240",
            "fraction": "REST",
            "designation": "STANDAARD"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 19
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/3\/pois"
                }
            },
            "profile": {
                "data": {
                    "type": "profile",
                    "id": 90
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/3\/profiles"
                }
            },
            "events": {
                "data": [
                    {
                        "type": "event",
                        "id": 1
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/3\/events"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/product\/3"
        }
    },
    "links": []
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/events/{event}/deliver-product

returns a product linked to a specific product field history


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/product-field-history/1/product" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-field-history/1/product");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 2,
            "total": 2,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "product",
            "id": 123456,
            "attributes": {
                "created_at": "2019-01-01T12:00:00+00:00",
                "updated_at": "2019-01-01T12:00:00+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "bin_product",
                "status": "active",
                "chipcode": "00004849106721",
                "barcode": "111111",
                "labelcode": null,
                "bincode": null,
                "description": "CONTAINER",
                "volume": "240",
                "fraction": "PMD",
                "designation": "STANDAARD"
            },
            "relationships": {
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 19
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/22361\/pois"
                    }
                },
                "profile": {
                    "data": {
                        "type": "profile",
                        "id": 89
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/22361\/profiles"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/22361"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/products",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/products?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/products?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/product-field-history/{productFieldHistory}/product

POST Product


Requires authentication Creates a new product

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/products" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"product","attributes":{"category":"bin_product","chipcode":"111111","barcode":"111111","labelcode":"111111","tags":"tag1, tag2"},"relationships":{"profiles":{"data":[{"id":2,"type":"profile"}]},"pois":{"data":[{"id":3,"type":"poi"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/products");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "product",
        "attributes": {
            "category": "bin_product",
            "chipcode": "111111",
            "barcode": "111111",
            "labelcode": "111111",
            "tags": "tag1, tag2"
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "id": 2,
                        "type": "profile"
                    }
                ]
            },
            "pois": {
                "data": [
                    {
                        "id": 3,
                        "type": "poi"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product",
        "id": 134118,
        "attributes": {
            "created_at": "2019-07-09T12:27:12+00:00",
            "updated_at": "2019-07-09T12:27:12+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "bin_product",
            "status": null,
            "chipcode": "1111111",
            "barcode": "1111111",
            "labelcode": null
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/134118\/pois"
                }
            },
            "profile": {
                "data": {
                    "type": "profile",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/134118\/profiles"
                }
            },
            "events": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/134118\/events"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/134118"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.relationships.profile.data.type": [
            "The data.relationships.profile.data.type field is required."
        ],
        "data.relationships.profile.data.id": [
            "The data.relationships.profile.data.id field is required."
        ]
    }
}

HTTP Request

POST api/v1/products

Body Parameters

Parameter Type Status Description
data.type string required Type must be product.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.chipcode string optional optional chipcode of this product.
data.attributes.barcode string optional optional barcode of this product.
data.attributes.labelcode string optional optional labelcode of this product.
data.attributes.tags array optional optional tags of this product.
data.relationships.profiles.data.*.id integer optional optional Profile id.
data.relationships.profiles.data.*.type string optional optional Profile type must be profile.
data.relationships.pois.data.*.id integer required Poi id.
data.relationships.pois.data.*.type string required Poi type must be poi.

PATCH Product


Requires authentication Update a specific product

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/products/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"products","id":1,"attributes":{"category":"bin_product","chipcode":"111111","barcode":"111111","labelcode":"111111","tags":"tag1, tag2"},"relationships":{"profiles":{"data":[{"id":2,"type":"profile"}]},"pois":{"data":[{"id":3,"type":"poi"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/products/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "products",
        "id": 1,
        "attributes": {
            "category": "bin_product",
            "chipcode": "111111",
            "barcode": "111111",
            "labelcode": "111111",
            "tags": "tag1, tag2"
        },
        "relationships": {
            "profiles": {
                "data": [
                    {
                        "id": 2,
                        "type": "profile"
                    }
                ]
            },
            "pois": {
                "data": [
                    {
                        "id": 3,
                        "type": "poi"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product",
        "id": 134119,
        "attributes": {
            "created_at": "2019-07-09T12:28:45+00:00",
            "updated_at": "2019-07-09T12:29:07+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "bin_product",
            "status": null,
            "chipcode": "11111112",
            "barcode": "1111111",
            "labelcode": null
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/134119\/pois"
                }
            },
            "profile": {
                "data": {
                    "type": "profile",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/134119\/profiles"
                }
            },
            "events": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/134119\/events"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/134119"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.relationships.profile.data.type": [
            "The data.relationships.profile.data.type field is required."
        ],
        "data.relationships.profile.data.id": [
            "The data.relationships.profile.data.id field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/products/{product}

Body Parameters

Parameter Type Status Description
data.type string optional optional Type must be products.
data.id integer required The id must match the url id.
data.attributes.category string optional optional One of the categories mentioned at the top of this page.
data.attributes.chipcode string optional optional chipcode of this product.
data.attributes.barcode string optional optional barcode of this product.
data.attributes.labelcode string optional optional labelcode of this product.
data.attributes.tags array optional optional tags of this product.
data.relationships.profiles.data.*.id integer optional optional Profile id.
data.relationships.profiles.data.*.type string optional optional Profile type must be profile.
data.relationships.pois.data.*.id integer optional optional Poi id.
data.relationships.pois.data.*.type string optional optional Poi type must be poi.

Replaced by v2 call.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/registrations/1/product" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/registrations/1/product");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/registrations/{registration}/product

ProductStatusHistory Requests

API calls for managing ProductStatusHistory

Available statuses

Name Description
active
auto_blocked
blocked
inactive

GET Product status histories


Requires authentication returns all product-status-history

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/product-status-history? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-status-history");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 49751,
            "last_page": 498
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "product-status-history",
            "id": 1,
            "attributes": {
                "created_at": "2019-07-04T12:34:56+00:00",
                "updated_at": "2019-07-04T12:34:56+00:00",
                "deleted_at": null,
                "product_id": 1,
                "status": "active",
                "from": "2016-01-01T12:34:56+00:00"
            },
            "relationships": {
                "product": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1\/products"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-status-history\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-status-history",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/product-status-history?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/product-status-history?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/product-status-history?page[number]=498"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/product-status-history

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[status] optional Filter specific product-status-history status.
filter[from_date] optional Find product-status-history with given from_date.
filter[from_min] optional product-status-history with a from date min.
filter[from_max] optional product-status-history with a from date max.
filter[from_between] optional Filter from between two dates (inclusive).
filter[product_id] optional Filter specific product-status-history product.
filter[until_between] optional Filter until between two dates (inclusive).

POST Product status history


Requires authentication creates a specific product-status-history

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/product-status-history" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"product-status-history","attributes":{"status":"active","from_date":"2019-05-10"},"relationships":{"product":{"data":[{"id":2,"type":"products"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-status-history");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "product-status-history",
        "attributes": {
            "status": "active",
            "from_date": "2019-05-10"
        },
        "relationships": {
            "product": {
                "data": [
                    {
                        "id": 2,
                        "type": "products"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product-status-history",
        "id": 152190,
        "attributes": {
            "created_at": "2019-07-09T11:28:42+00:00",
            "updated_at": "2019-07-09T11:28:42+00:00",
            "deleted_at": null,
            "product_id": 1,
            "status": "active",
            "from": "2016-01-01T12:34:56+00:00"
        },
        "relationships": {
            "product": {
                "data": {
                    "type": "product",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/152190\/products"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-status-history\/152190"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.status": [
            "The data.attributes.status field is required."
        ],
        "data.attributes.from_date": [
            "The data.attributes.from date field is required."
        ],
        "data.relationships.product.data.type": [
            "The data.relationships.product.data.type field is required."
        ],
        "data.relationships.product.data.id": [
            "The data.relationships.product.data.id field is required."
        ]
    }
}

HTTP Request

POST api/v1/product-status-history

Body Parameters

Parameter Type Status Description
data.type string required Type must be product-status-history.
data.attributes.status string required One of the statuses mentioned at the top of this page.
data.attributes.from_date date required From date.
data.relationships.product.data.*.id integer required Profile id.
data.relationships.product.data.*.type string required Profile type must be products.

PATCH Product status history


Requires authentication Update a product status history.

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/product-status-history/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"product-status-history","id":1,"attributes":{"status":"active","from_date":"2019-05-10"},"relationships":{"product":{"data":[{"id":"2","type":"products"}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-status-history/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "product-status-history",
        "id": 1,
        "attributes": {
            "status": "active",
            "from_date": "2019-05-10"
        },
        "relationships": {
            "product": {
                "data": [
                    {
                        "id": "2",
                        "type": "products"
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product-status-history",
        "id": 152191,
        "attributes": {
            "created_at": "2019-07-09T11:39:58+00:00",
            "updated_at": "2019-07-09T11:40:25+00:00",
            "deleted_at": null,
            "product_id": 1,
            "status": "active",
            "from": "2016-01-01T12:34:56+00:00"
        },
        "relationships": {
            "product": {
                "data": {
                    "type": "product",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/152191\/products"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-status-history\/152191"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.id": [
            "The data.id field is required."
        ],
        "data.attributes": [
            "The data.attributes field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/product-status-history/{productStatusHistory}

Body Parameters

Parameter Type Status Description
data.type string optional optional Type must be product-status-history.
data.id integer required The id must match the url id.
data.attributes.status string optional optional One of the statuses mentioned at the top of this page.
data.attributes.from_date date optional optional From date.
data.relationships.product.data.*.id optional optional Profile id.
data.relationships.product.data.*.type optional optional Profile type must be products.

GET Product status history


Requires authentication returns a specific product-status-history

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/product-status-history/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/product-status-history/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "product-status-history",
        "id": 1,
        "attributes": {
            "created_at": "2019-07-04T12:47:42+00:00",
            "updated_at": "2019-07-04T12:47:42+00:00",
            "deleted_at": null,
            "product_id": 1,
            "status": "active",
            "from": "2016-01-01T12:34:56+00:00"
        },
        "relationships": {
            "product": {
                "data": {
                    "type": "product",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1\/products"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-status-history\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/product-status-history/{productStatusHistory}

GET Product status history from Product


Requires authentication returns profiles linked to a specific calendar

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/products/1/product-status-history" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/products/1/product-status-history");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "product-status-history",
            "id": 1,
            "attributes": {
                "created_at": "2019-07-04T12:47:42+00:00",
                "updated_at": "2019-07-04T12:47:42+00:00",
                "deleted_at": null,
                "product_id": 1,
                "status": "active",
                "from": "2016-01-01T12:34:56+00:00"
            },
            "relationships": {
                "product": {
                    "data": {
                        "type": "product",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/product-related-pois\/1\/products"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/product-status-history\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/1\/product-status-history",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/products\/1\/product-status-history?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/products\/1\/product-status-history?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/products/{product}/product-status-history

Profile Children

Group combining all endpoints related to the children of a specific profile.

Class ProfileChildrenController

GET Children for profile.


Requires authentication Endpoint to retrieve all the children for a given profile.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1/children" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1/children");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 4100,
            "attributes": {
                "created_at": "2020-02-06T12:54:57+00:00",
                "updated_at": "2020-02-06T12:54:57+00:00",
                "deleted_at": null,
                "tags": [],
                "category": "chipcard_product_profile",
                "link_id": 8380,
                "properties": []
            },
            "relationships": {
                "options": {
                    "data": [
                        {
                            "id": 2119,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2120,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2121,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2122,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        }
                    ]
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/4100"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/profiles?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/profiles?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/profiles/{profile}/children

Profile ExcludedProfiles

Group to bundle all the endpoints related to the Excluded Profiles of a specific Profile.

Class ProfileExcludedProfilesController

GET index

Endpoint to retrieve all the ExcludeProfileWhere entities for a specific Profile entity.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1/excluded-profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1/excluded-profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 3,
            "total": 3,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "excluded-profile",
            "id": 69,
            "attributes": {
                "created_at": "2020-02-27T10:06:43+00:00",
                "updated_at": "2020-02-27T10:06:43+00:00",
                "deleted_at": null,
                "profile_id": 9341,
                "where_profile_id": 9342,
                "where_entity_type": "poi",
                "where_geo_location_id": 487
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/excluded-profiles\/69"
            }
        },
        {
            "type": "excluded-profile",
            "id": 70,
            "attributes": {
                "created_at": "2020-02-27T10:06:43+00:00",
                "updated_at": "2020-02-27T10:06:43+00:00",
                "deleted_at": null,
                "profile_id": 9341,
                "where_profile_id": 9343,
                "where_entity_type": "poi",
                "where_geo_location_id": 488
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/excluded-profiles\/70"
            }
        },
        {
            "type": "excluded-profile",
            "id": 71,
            "attributes": {
                "created_at": "2020-02-27T10:06:43+00:00",
                "updated_at": "2020-02-27T10:06:43+00:00",
                "deleted_at": null,
                "profile_id": 9341,
                "where_profile_id": 9344,
                "where_entity_type": "poi",
                "where_geo_location_id": 489
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/excluded-profiles\/71"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/9341\/excluded-profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/9341\/excluded-profiles?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/9341\/excluded-profiles?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/profiles/{profile}/excluded-profiles

Profile GeoLocations

Group to bundle all the endpoints related to the GeoLocations of a specific Profile.

Class ProfileGeoLocationsController

GET Index


Requires authentication Endpoint to fetch all the GeoLocations related to a specific Profile entity.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1/geo-locations" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1/geo-locations");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 391,
            "last_page": 4
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "geo-location",
            "id": 3,
            "attributes": {
                "created_at": "2015-12-23T14:22:23+00:00",
                "updated_at": "2015-12-23T14:22:23+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "city_geo_location",
                "name": "DEFAULT",
                "external_id": null,
                "code": null
            },
            "relationships": {
                "parent": {
                    "data": {
                        "type": "geo-location",
                        "id": 1
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/3\/parent"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations\/3"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/geo-locations?page[number]=4"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/profiles/{profile}/geo-locations

Profile Options

Group to collect all the endpoints related to the Options relationship for a given profile.

Class ProfileOptionsController

GET Index


Requires authentication Endpoint to retrieve all the Option entities for a given Profile entity.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1/options" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1/options");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 699,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "option",
            "id": 1,
            "attributes": {
                "created_at": "2012-09-25T17:48:14+00:00",
                "updated_at": "2019-07-19T11:06:24+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "other_garbage_event_origin",
                "name": "Burger"
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/options",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/options?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/options?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/options?page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/profiles/{profile}/options

Profile Requests

API calls for managing Profiles

Available categories:

Name Description
bin_product_profile
chipcard_product_profile
other_garbage_event_profile
ciaccess_product_profile
ident_system_profile
ident_communication_profile
accessibility_profile
holiday_profile
operation_profile
action_event_profile
complaint_event_profile
poi_profile
info_request_event_profile

Available kinds:

Name Description
card
chipcard
product
ci-access

Available action types:

Name Description
ciaccess_inquiry
ciaccess_interruption_inquiry
collect_product
inquiry
interruption_inquiry
new_chipcard
new_product
repair_ciaccess_product
repair_product
replace_chip_product
replace_dotation_product
replace_product

Available chipcards:

Name Description
userpass
masterpass

GET Profiles from Calendar


Requires authentication returns profiles linked to a specific calendar

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 93,
            "attributes": {
                "created_at": "2016-01-19T10:02:27+00:00",
                "updated_at": "2016-01-19T10:02:27+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "bin_product_profile",
                "description": "CONTAINER",
                "fraction": "GFT",
                "volume": "140",
                "designation": "STANDAARD",
                "properties": []
            },
            "relationships": {
                "description": {
                    "data": {
                        "type": "option",
                        "id": 307
                    }
                },
                "fraction": {
                    "data": {
                        "type": "option",
                        "id": 330
                    }
                },
                "volume": {
                    "data": {
                        "type": "option",
                        "id": 363
                    }
                },
                "designation": {
                    "data": {
                        "type": "option",
                        "id": 388
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/93"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1\/profiles?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/calendars/{calendar}/profiles

GET Profiles from Event


Requires authentication returns profiles linked to a specific event

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/events/1/profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"profile","attributes":{"category":"bin_product_profile","properties":{"kind":"card","action_type":"ciaccess_inquiry","rate":"Example calendar","show-memo":"true","show-date":"true","show-type":"true","memo-required":"true","show-location":true,"show-container-number":true,"name":"Example test_name","function_of_card":"Example masterpass"}},"relationships":{"name":{"data":{"id":0}},"description":{"data":{"id":"1"}},"subject":{"data":{"id":"Example 1"}},"location":{"data":{"id":"Example 1"}},"model":{"data":{"id":"Example 123"}},"options":{"description":"Example 1","fraction":"Example 23","volume":"Example 45","designation":"Example 67"}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/events/1/profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "profile",
        "attributes": {
            "category": "bin_product_profile",
            "properties": {
                "kind": "card",
                "action_type": "ciaccess_inquiry",
                "rate": "Example calendar",
                "show-memo": "true",
                "show-date": "true",
                "show-type": "true",
                "memo-required": "true",
                "show-location": true,
                "show-container-number": true,
                "name": "Example test_name",
                "function_of_card": "Example masterpass"
            }
        },
        "relationships": {
            "name": {
                "data": {
                    "id": 0
                }
            },
            "description": {
                "data": {
                    "id": "1"
                }
            },
            "subject": {
                "data": {
                    "id": "Example 1"
                }
            },
            "location": {
                "data": {
                    "id": "Example 1"
                }
            },
            "model": {
                "data": {
                    "id": "Example 123"
                }
            },
            "options": {
                "description": "Example 1",
                "fraction": "Example 23",
                "volume": "Example 45",
                "designation": "Example 67"
            }
        }
    }
}

fetch(url, {
    method: "GET",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 712,
            "attributes": {
                "created_at": "2012-09-25T17:29:35+00:00",
                "updated_at": "2016-03-07T10:18:27+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "info_request_event_profile",
                "description": "Info algemeen",
                "properties": []
            },
            "relationships": {
                "description": {
                    "data": {
                        "type": "option",
                        "id": 832
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/712"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/events\/30\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/events\/30\/profiles?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/events\/30\/profiles?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/events/{event}/profiles

Body Parameters

Parameter Type Status Description
data.type string required Type must be profile.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.relationships.name.data.id integer optional optional required for Name for the Profile.
data.attributes.properties.kind string optional optional required for One of the kinds mentioned at the top of this page.
data.attributes.properties.action_type optional required for One of the action types mentioned at the top of this page.
data.attributes.properties.rate optional required for Rate for the Profile.
data.attributes.properties.show-memo optional required for Show memo for the Profile.
data.attributes.properties.show-date optional required for Show date for the Profile.
data.attributes.properties.show-type optional required for Show type for the Profile.
data.attributes.properties.memo-required optional required for Memo required for the Profile.
data.attributes.properties.show-location boolean optional optional required for Show location for the Profile.
data.attributes.properties.show-container-number boolean optional optional required for Show container number for the Profile.
data.relationships.description.data.id required optional for <complaint_event_profile, chipcard_product_profile, other_garbage_event_profile> Description id for the Profile.
data.relationships.subject.data.id required optional for Subject for the Profile.
data.relationships.location.data.id required optional for Location for the Profile.
data.relationships.model.data.id required optional for Model for the Profile.
data.attributes.properties.name required optional for <chipcard_product_profile, ciaccess_product_profile> Name for the Profile.
data.attributes.properties.function_of_card required optional for Card type for the Profile.
data.relationships.options.description required optional for Description for the Profile.
data.relationships.options.fraction required optional for Fraction for the Profile.
data.relationships.options.volume required optional for Volume for the Profile.
data.relationships.options.designation required optional for Designation for the Profile.

GET profiles from Person


Requires authentication returns profiles linked to a specific Person

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/persons/1/profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/persons/1/profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 1,
            "attributes": {
                "created_at": "2019-07-04T11:50:58+00:00",
                "updated_at": "2019-07-04T11:50:58+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "complaint_event_profile",
                "description": "klacht ophaling restafval",
                "subject": "container niet leeggemaakt",
                "location": "alleen bij deze burger",
                "properties": {
                    "show_memo": false,
                    "show_date": false,
                    "show_time": false,
                    "memo_required": false,
                    "show_location": false,
                    "show_container_number": false
                }
            },
            "relationships": {
                "description": {
                    "data": {
                        "type": "option",
                        "id": 176
                    }
                },
                "subject": {
                    "data": {
                        "type": "option",
                        "id": 220
                    }
                },
                "location": {
                    "data": {
                        "type": "option",
                        "id": 271
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14\/profiles?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/14\/profiles?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/persons/{person}/profiles

GET profiles from POI


Requires authentication returns profiles linked to a specific poi

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 148,
            "last_page": 2
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 1,
            "attributes": {
                "created_at": "2019-07-04T11:50:58+00:00",
                "updated_at": "2019-07-04T11:50:58+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "complaint_event_profile",
                "description": "klacht ophaling restafval",
                "subject": "container niet leeggemaakt",
                "location": "alleen bij deze burger",
                "properties": {
                    "show_memo": false,
                    "show_date": false,
                    "show_time": false,
                    "memo_required": false,
                    "show_location": false,
                    "show_container_number": false
                }
            },
            "relationships": {
                "description": {
                    "data": {
                        "type": "option",
                        "id": 176
                    }
                },
                "subject": {
                    "data": {
                        "type": "option",
                        "id": 220
                    }
                },
                "location": {
                    "data": {
                        "type": "option",
                        "id": 271
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/profiles?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/profiles?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/profiles?page[number]=2"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/pois/{poi}/profiles

GET available Profiles from POI


Requires authentication returns available profiles linked to a specific poi

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/available_profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/available_profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 146,
            "last_page": 2
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 1,
            "attributes": {
                "created_at": "2019-07-04T11:50:58+00:00",
                "updated_at": "2019-07-04T11:50:58+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "complaint_event_profile",
                "description": "klacht ophaling restafval",
                "subject": "container niet leeggemaakt",
                "location": "alleen bij deze burger",
                "properties": {
                    "show_memo": false,
                    "show_date": false,
                    "show_time": false,
                    "memo_required": false,
                    "show_location": false,
                    "show_container_number": false
                }
            },
            "relationships": {
                "description": {
                    "data": {
                        "type": "option",
                        "id": 176
                    }
                },
                "subject": {
                    "data": {
                        "type": "option",
                        "id": 220
                    }
                },
                "location": {
                    "data": {
                        "type": "option",
                        "id": 271
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/available_profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/available_profiles?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/available_profiles?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/19\/available_profiles?page[number]=2"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/pois/{poi}/available_profiles

GET Profiles from Product


Requires authentication returns profiles linked to a specific product

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/products/1/profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/products/1/profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 94,
            "attributes": {
                "created_at": "2016-01-19T10:02:54+00:00",
                "updated_at": "2016-01-19T10:02:54+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "bin_product_profile",
                "description": "CONTAINER",
                "fraction": "REST",
                "volume": "140",
                "designation": "SLOT",
                "properties": []
            },
            "relationships": {
                "description": {
                    "data": {
                        "type": "option",
                        "id": 307
                    }
                },
                "fraction": {
                    "data": {
                        "type": "option",
                        "id": 328
                    }
                },
                "volume": {
                    "data": {
                        "type": "option",
                        "id": 363
                    }
                },
                "designation": {
                    "data": {
                        "type": "option",
                        "id": 386
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/94"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/profiles?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/products\/14\/profiles?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/products/{product}/profiles

GET Profiles


Requires authentication returns all profiles

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/profiles? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/profiles");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 332,
            "last_page": 4
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 1,
            "attributes": {
                "created_at": "2019-07-04T11:50:58+00:00",
                "updated_at": "2019-07-04T11:50:58+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": null,
                "category": "complaint_event_profile",
                "description": "klacht ophaling restafval",
                "subject": "container niet leeggemaakt",
                "location": "alleen bij deze burger",
                "properties": {
                    "show_memo": false,
                    "show_date": false,
                    "show_time": false,
                    "memo_required": false,
                    "show_location": false,
                    "show_container_number": false
                }
            },
            "relationships": {
                "description": {
                    "data": {
                        "type": "option",
                        "id": 176
                    }
                },
                "subject": {
                    "data": {
                        "type": "option",
                        "id": 220
                    }
                },
                "location": {
                    "data": {
                        "type": "option",
                        "id": 271
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/profiles?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/profiles?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/profiles?page[number]=4"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/profiles

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific Profile category.
filter[product_id] optional Find Calendar with given name.
filter[calendar_id] optional Calendars from a certain date.
filter[event_id] optional Calendars until a certain date.
filter[available] optional Calendars until a certain date.

POST Profile


Requires authentication Creates a specific Profiles

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"profile","attributes":{"category":"bin_product_profile","properties":{"kind":"card","action_type":"ciaccess_inquiry","rate":"calendar","show-memo":true,"show-date":true,"show-type":true,"memo-required":true,"show-location":true,"show-container-number":true,"name":"test_name","function_of_card":"masterpass"}},"relationships":{"name":{"data":{"id":0}},"description":{"data":{"id":1}},"subject":{"data":{"id":1}},"location":{"data":{"id":1}},"model":{"data":{"id":123}},"options":{"description":0,"fraction":"Example GFT","volume":"Example 120","designation":"Stanard"}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "profile",
        "attributes": {
            "category": "bin_product_profile",
            "properties": {
                "kind": "card",
                "action_type": "ciaccess_inquiry",
                "rate": "calendar",
                "show-memo": true,
                "show-date": true,
                "show-type": true,
                "memo-required": true,
                "show-location": true,
                "show-container-number": true,
                "name": "test_name",
                "function_of_card": "masterpass"
            }
        },
        "relationships": {
            "name": {
                "data": {
                    "id": 0
                }
            },
            "description": {
                "data": {
                    "id": 1
                }
            },
            "subject": {
                "data": {
                    "id": 1
                }
            },
            "location": {
                "data": {
                    "id": 1
                }
            },
            "model": {
                "data": {
                    "id": 123
                }
            },
            "options": {
                "description": 0,
                "fraction": "Example GFT",
                "volume": "Example 120",
                "designation": "Stanard"
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "profile",
        "id": 1239,
        "attributes": {
            "created_at": "2019-07-08T12:50:21+00:00",
            "updated_at": "2019-07-08T12:50:21+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "action_event_profile",
            "kind": null,
            "action_type": null,
            "name": null,
            "rate": null,
            "properties": []
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/1239"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.attributes.category field is required."
        ]
    }
}

HTTP Request

POST api/v1/profiles

Body Parameters

Parameter Type Status Description
data.type string required Type must be profile.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.relationships.name.data.id integer optional optional required for Name for the Profile.
data.attributes.properties.kind string optional optional required for One of the kinds mentioned at the top of this page.
data.attributes.properties.action_type string optional optional required for One of the action types mentioned at the top of this page.
data.attributes.properties.rate string optional optional required for Rate for the Profile.
data.attributes.properties.show-memo boolean optional optional required for Show memo for the Profile.
data.attributes.properties.show-date boolean optional optional required for Show date for the Profile.
data.attributes.properties.show-type boolean optional optional required for Show type for the Profile.
data.attributes.properties.memo-required boolean optional optional required for Memo required for the Profile.
data.attributes.properties.show-location boolean optional optional required for Show location for the Profile.
data.attributes.properties.show-container-number boolean optional optional required for Show container number for the Profile.
data.relationships.description.data.id integer optional optional required for <complaint_event_profile, chipcard_product_profile, other_garbage_event_profile> Description id for the Profile.
data.relationships.subject.data.id integer optional optional required for Subject for the Profile.
data.relationships.location.data.id integer optional optional required for Location for the Profile.
data.relationships.model.data.id integer optional optional required for Model for the Profile.
data.attributes.properties.name string optional optional required for <chipcard_product_profile, ciaccess_product_profile> Name for the Profile.
data.attributes.properties.function_of_card string optional optional required for Card type for the Profile.
data.relationships.options.description integer optional optional required for Description for the Profile.
data.relationships.options.fraction string optional optional required for Fraction for the Profile.
data.relationships.options.volume string optional optional Required for Volume for the Profile.
data.relationships.options.designation string optional optional Required for Designation for the Profile.

GET Profile


Requires authentication returns a specific profile

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/profiles/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/profiles/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "profile",
        "id": 14,
        "attributes": {
            "created_at": "2019-07-04T11:50:58+00:00",
            "updated_at": "2019-07-04T11:50:58+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "complaint_event_profile",
            "description": "Klacht: afvalkalender",
            "subject": "Klacht: niet ontvangen",
            "location": "Enkel bij deze bewoner",
            "properties": {
                "show_memo": true,
                "show_date": false,
                "show_time": false,
                "memo_required": true,
                "show_location": false,
                "show_container_number": false
            }
        },
        "relationships": {
            "description": {
                "data": {
                    "type": "option",
                    "id": 181
                }
            },
            "subject": {
                "data": {
                    "type": "option",
                    "id": 227
                }
            },
            "location": {
                "data": {
                    "type": "option",
                    "id": 277
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/14"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/profiles/{profile}

PATCH Profile


Requires authentication updates a specific profile

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/profiles/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"profile","id":1,"attributes":{"category":"bin_product_profile","properties":{"kind":"card","action_type":"ciaccess_inquiry","rate":"calendar","show-memo":true,"show-date":true,"show-type":true,"memo-required":true,"show-location":true,"show-container-number":true,"name":"test_name","function_of_card":"masterpass"}},"relationships":{"name":{"data":{"id":0}},"description":{"data":{"id":1}},"subject":{"data":{"id":1}},"location":{"data":{"id":1}},"model":{"data":{"id":123}},"options":{"description":"1","fraction":"GFT","volume":"120","designation":"Standard"}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/profiles/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "profile",
        "id": 1,
        "attributes": {
            "category": "bin_product_profile",
            "properties": {
                "kind": "card",
                "action_type": "ciaccess_inquiry",
                "rate": "calendar",
                "show-memo": true,
                "show-date": true,
                "show-type": true,
                "memo-required": true,
                "show-location": true,
                "show-container-number": true,
                "name": "test_name",
                "function_of_card": "masterpass"
            }
        },
        "relationships": {
            "name": {
                "data": {
                    "id": 0
                }
            },
            "description": {
                "data": {
                    "id": 1
                }
            },
            "subject": {
                "data": {
                    "id": 1
                }
            },
            "location": {
                "data": {
                    "id": 1
                }
            },
            "model": {
                "data": {
                    "id": 123
                }
            },
            "options": {
                "description": "1",
                "fraction": "GFT",
                "volume": "120",
                "designation": "Standard"
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "profile",
        "id": 1239,
        "attributes": {
            "created_at": "2019-07-08T12:50:21+00:00",
            "updated_at": "2019-07-08T12:54:22+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "action_event_profile",
            "kind": "chipcard",
            "action_type": "new_product",
            "name": null,
            "rate": null,
            "properties": {
                "kind": "chipcard",
                "action_type": "new_product"
            }
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/profiles\/1239"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.attributes.category field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/profiles/{profile}

Body Parameters

Parameter Type Status Description
data.type string required Type must be profile.
data.id integer required The id must match the url id.
data.attributes.category string optional optional One of the categories mentioned at the top of this page.
data.relationships.name.data.id integer optional optional Name for the Profile.
data.attributes.properties.kind string optional optional One of the kinds mentioned at the top of this page.
data.attributes.properties.action_type string optional optional One of the action types mentioned at the top of this page.
data.attributes.properties.rate optional optional string Rate for the Profile.
data.attributes.properties.show-memo boolean optional optional Show memo for the Profile.
data.attributes.properties.show-date boolean optional optional Show date for the Profile.
data.attributes.properties.show-type boolean optional optional Show type for the Profile.
data.attributes.properties.memo-required boolean optional optional Memo required for the Profile.
data.attributes.properties.show-location boolean optional optional Show location for the Profile.
data.attributes.properties.show-container-number boolean optional optional Show container number for the Profile.
data.relationships.description.data.id integer optional optional Description id for the Profile.
data.relationships.subject.data.id integer optional optional Subject for the Profile.
data.relationships.location.data.id integer optional optional Location for the Profile.
data.relationships.model.data.id integer optional optional Model for the Profile.
data.attributes.properties.name string optional optional Name for the Profile.
data.attributes.properties.function_of_card string optional optional Card type for the Profile.
data.relationships.options.description string optional optional Description for the Profile.
data.relationships.options.fraction string optional optional Fraction for the Profile.
data.relationships.options.volume string optional optional Volume for the Profile.
data.relationships.options.designation string optional optional Designation for the Profile.

DELETE Profile

Delete a specific profile


Requires authentication

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/profiles/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/profiles/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v1/profiles/{profile}

Profile V2 Requests

API calls (v2) for retrieving and managing Profiles.

Class ProfileController

GET Profiles


Requires authentication Return all the profiles.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/profiles? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/profiles");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 4100,
            "attributes": {
                "created_at": "2020-02-06T12:54:57+00:00",
                "updated_at": "2020-02-06T12:54:57+00:00",
                "deleted_at": null,
                "tags": [],
                "category": "chipcard_product_profile",
                "link_id": 8380,
                "properties": []
            },
            "relationships": {
                "options": {
                    "data": [
                        {
                            "id": 2119,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2120,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2121,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2122,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        }
                    ]
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/4100"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/profiles?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/profiles?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/profiles

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter on specific Profile category or categories.
filter[link] optional Filter profiles on having a specific link id(s).
filter[product] optional Filter profiles on having specific Product(s).
filter[person] optional Filter profiles on having specific Person(s).
filter[calendar] optional Filter on profiles having specific Calendar(s).
filter[event] optional Filter profiles having specific Event(s).
filter[poi] optional Filter profiles directly (through api_entity_profiles) on belonging to a specific Poi(s).
filter[allowedForPoi] optional Filter on profiles that are allowed for a given (set of) Poi(s).
filter[customer] optional Filter profiles belonging to a specific Customer(s).
filter[geo-location] optional Filter profiles applicable for a certain GeoLocation(s).
filter[option] optional Filter profiles having specific Option(s).
filter[available] optional Filter profiles having specific available Geo Locations.
filter[notAvailable] optional Filter profiles having specific GeoLocations not available.
filter[actionType] optional Filter profiles on specific action type.

POST Profile

Endpoint to create a new (v2) Profile

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v2/profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (422):

[]

HTTP Request

POST api/v2/profiles

GET Profile


Requires authentication Return a specific profile.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "profile",
        "id": 4411,
        "attributes": {
            "created_at": "2020-02-06T13:51:14+00:00",
            "updated_at": "2020-02-06T13:51:14+00:00",
            "deleted_at": null,
            "tags": [],
            "category": "chipcard_product_profile",
            "link_id": 8679,
            "properties": [],
            "complaint_event_profile_description": "Bettie"
        },
        "relationships": {
            "options": {
                "data": [
                    {
                        "id": 2119,
                        "type": "option",
                        "attributes": {
                            "category": "complaint_event_profile_description"
                        }
                    },
                    {
                        "id": 2120,
                        "type": "option",
                        "attributes": {
                            "category": "complaint_event_profile_description"
                        }
                    },
                    {
                        "id": 2121,
                        "type": "option",
                        "attributes": {
                            "category": "complaint_event_profile_description"
                        }
                    },
                    {
                        "id": 2122,
                        "type": "option",
                        "attributes": {
                            "category": "complaint_event_profile_description"
                        }
                    }
                ]
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/4411"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/profiles/{profile}

DELETE Profile.


Requires authentication Endpoint to delete a specific profile.

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

DELETE api/v2/profiles/{profile}

PATCH Profile

Endpoint to update a specific Profile.

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "PATCH",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (422):

[]

HTTP Request

PATCH api/v2/profiles/{profile}

Profile parent

Group to bundle all the endpoints related to the parent relation of a profile entity.

Class ProfileParentController

GET Index


Requires authentication Endpoint to retrieve the parent profile for a child profile.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1/parent" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/profiles/1/parent");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "profile",
            "id": 4100,
            "attributes": {
                "created_at": "2020-02-06T12:54:57+00:00",
                "updated_at": "2020-02-06T12:54:57+00:00",
                "deleted_at": null,
                "tags": [],
                "category": "chipcard_product_profile",
                "link_id": 8380,
                "properties": []
            },
            "relationships": {
                "options": {
                    "data": [
                        {
                            "id": 2119,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2120,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2121,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        },
                        {
                            "id": 2122,
                            "type": "option",
                            "attributes": {
                                "category": "complaint_event_profile_description"
                            }
                        }
                    ]
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/4100"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/profiles?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/profiles?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/profiles/{profile}/parent

Registration

API calls for managing Registrations

Available categories:

Name Description
emptying_registration
ciaccess_dumping_registration
ciaccess_emptying_registration
recycling_center_dumping_registration
recycling_center_visit_registration

Allowed filters:

?filter[id]={registrationId}

?filter[category]={categoryName}

?filter[product]={productId}

?filter[registeredAt]={registeredAt}

?filter[registeredQuantity]={registeredQuantity}

?filter[validatedQuantity]={validatedQuantity}

?filter[registeredUnit]={registeredUnit}

?filter[chipcode]={chipcode}

?filter[latitude]={latitude}

?filter[longitude]={longitude}

?filter[error]={error}

Allowed sortables:

?sort=registered_at,-registered_at

POST Registration


Requires authentication Store a new registration

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/registrations" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"registration","attributes":{"category":"emptying_registration","unit":"Example kg","registered_at":"Example 2019-01-01","status_code":0,"chipcode":"Example 0040292390303"},"relationships":{"customer":{"data":[{"id":6}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/registrations");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "registration",
        "attributes": {
            "category": "emptying_registration",
            "unit": "Example kg",
            "registered_at": "Example 2019-01-01",
            "status_code": 0,
            "chipcode": "Example 0040292390303"
        },
        "relationships": {
            "customer": {
                "data": [
                    {
                        "id": 6
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "registration",
        "id": 2,
        "attributes": {
            "created_at": "2019-07-08T13:23:47+00:00",
            "updated_at": "2019-07-08T13:23:47+00:00",
            "deleted_at": null,
            "tags": [
                "tag_a"
            ],
            "link_id": null,
            "category": "emptying_registration",
            "registered_at": "2019-01-01",
            "registered_quantity": 10,
            "validated_quantity": null,
            "unit": "kg",
            "chipcode": "0040292390303",
            "location": {
                "lat": null,
                "lon": null
            },
            "line": null,
            "status_code": 10,
            "external_id": null
        },
        "relationships": {
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 6
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/2\/customers"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/2"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.unit": [
            "The data.attributes.unit field is required."
        ],
        "data.attributes.registered_at": [
            "The data.attributes.registered at field is required."
        ],
        "data.attributes.status_code": [
            "The data.attributes.status code field is required."
        ],
        "data.attributes.chipcode": [
            "The data.attributes.chipcode field is required."
        ],
        "data.relationships.customer.data.id": [
            "The data.relationships.customer.data.id field is required."
        ]
    }
}

HTTP Request

POST api/v1/registrations

Body Parameters

Parameter Type Status Description
data.type string required Type must be registration.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.unit string required Unit of this Registration.
data.attributes.registered_at string required RegisteredAt of this Registration.
data.attributes.status_code integer required StatusCode of this Registration.
data.attributes.chipcode string required Chipcode of this Registration.
data.relationships.customer.data.*.id integer optional optional Profile id.

PATCH Registration


Requires authentication Update registration.

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/registrations/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":2,"type":"registration","attributes":{"category":"emptying_registration","unit":"Example kg","registered_at":"Example 2019-01-01","status_code":0,"chipcode":"Example 0040292390303"},"relationships":{"customer":{"data":[{"id":6}]}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/registrations/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": 2,
        "type": "registration",
        "attributes": {
            "category": "emptying_registration",
            "unit": "Example kg",
            "registered_at": "Example 2019-01-01",
            "status_code": 0,
            "chipcode": "Example 0040292390303"
        },
        "relationships": {
            "customer": {
                "data": [
                    {
                        "id": 6
                    }
                ]
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "registration",
        "id": 2,
        "attributes": {
            "created_at": "2019-07-08T13:23:47+00:00",
            "updated_at": "2019-07-08T13:32:26+00:00",
            "deleted_at": null,
            "tags": [
                "tag_b"
            ],
            "link_id": null,
            "category": "emptying_registration",
            "registered_at": "2019-01-01",
            "registered_quantity": 10,
            "validated_quantity": null,
            "unit": "kg",
            "chipcode": "0040292390303",
            "location": {
                "lat": null,
                "lon": null
            },
            "line": null,
            "status_code": 10,
            "external_id": null
        },
        "relationships": {
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 6
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/2\/customers"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/2"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes.category": [
            "The data.attributes.category field is required."
        ],
        "data.attributes.unit": [
            "The data.attributes.unit field is required."
        ],
        "data.attributes.registered_at": [
            "The data.attributes.registered at field is required."
        ],
        "data.attributes.status_code": [
            "The data.attributes.status code field is required."
        ],
        "data.attributes.chipcode": [
            "The data.attributes.chipcode field is required."
        ],
        "data.relationships.customer.data.id": [
            "The data.relationships.customer.data.id field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/registrations/{registration}

Body Parameters

Parameter Type Status Description
data.id integer required ID of registration to patch.
data.type string required Type must be registration.
data.attributes.category string required One of the categories mentioned at the top of this page.
data.attributes.unit string required Unit of this Registration.
data.attributes.registered_at string required RegisteredAt of this Registration.
data.attributes.status_code integer required StatusCode of this Registration.
data.attributes.chipcode string required Chipcode of this Registration.
data.relationships.customer.data.*.id integer optional optional Profile id.

GET Registration


Requires authentication returns a specific registration

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/registrations/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/registrations/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "registration",
        "id": 1,
        "attributes": {
            "created_at": "2016-01-02T17:21:16+00:00",
            "updated_at": "2016-01-02T17:30:02+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "emptying_registration",
            "registered_at": "2016-01-02",
            "registered_quantity": 30.5,
            "validated_quantity": null,
            "unit": "kg",
            "chipcode": "00004849005672",
            "location": {
                "lat": 51.62133,
                "lon": 4.85166
            },
            "line": "7",
            "status_code": null,
            "external_id": null
        },
        "relationships": {
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 6
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/1\/customers"
                }
            },
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 16424
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/1\/pois"
                }
            },
            "product": {
                "data": {
                    "type": "product",
                    "id": 16439
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/1\/product"
                }
            },
            "person": {
                "data": {
                    "type": "person",
                    "id": 16407
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/1\/people"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/registrations/{registration}

DELETE Registration


Requires authentication Destroy registration

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/registrations/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":2,"type":"registration"}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/registrations/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": 2,
        "type": "registration"
    }
}

fetch(url, {
    method: "DELETE",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The selected data.id is invalid."
        ],
        "data.type": [
            "The data.type value does not match required value."
        ]
    }
}

HTTP Request

DELETE api/v1/registrations/{registration}

Body Parameters

Parameter Type Status Description
data.id integer required ID of registration to delete.
data.type string required Type must be registration.

Status codes requests

API Calls related to Status codes.

Class StatusCodeController

GET Status codes


Requires authentication Returns all the status codes by type

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/status-codes" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/status-codes");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 3,
            "total": 3,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "status-code",
            "id": null,
            "attributes": {
                "status": "success",
                "range": "13000-13002",
                "codes": [
                    {
                        "code": 13000
                    },
                    {
                        "code": 13001
                    }
                ]
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/status-codes"
            }
        },
        {
            "type": "status-code",
            "id": null,
            "attributes": {
                "status": "internal",
                "range": "23000-23201",
                "codes": [
                    {
                        "code": 23000
                    },
                    {
                        "code": 23001
                    }
                ]
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/status-codes"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/status-codes",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/status-codes?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/status-codes?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (405):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 405,
        "source": null,
        "title": "Method Not Allowed",
        "detail": "The GET method is not supported for this route."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/status-codes

Tags

Tag endpoints

GET Tags


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/tags" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/tags");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 7,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "tag",
            "id": 1,
            "attributes": {
                "created_at": "2016-03-09T14:01:39+00:00",
                "updated_at": "2018-04-09T12:40:29+00:00",
                "deleted_at": null,
                "name": "Test Tag"
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/tags\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/tags",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/tags?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/tags?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/tags?page[number]=7"
    }
}

HTTP Request

GET api/v1/tags

User requests

API calls for managing Users

GET the authenticated user details.


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/users/me" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/users/me");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "user",
        "id": 1029,
        "attributes": {
            "created_at": "2019-04-11T07:07:50+00:00",
            "updated_at": "2019-07-04T11:50:50+00:00",
            "deleted_at": null,
            "username": "testUser",
            "lastname": "Doe",
            "firstname": "John",
            "email": "test@inovim.eu",
            "company": null
        },
        "relationships": {
            "roles": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/users\/1029\/roles"
                }
            },
            "group": {
                "data": {
                    "type": "group",
                    "id": 1
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/users\/1029\/group"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/users\/1029"
        }
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/users/me

V2/Calendar

API v2 endpoints for fetching and managing Calendar entities.

GET Index


Requires authentication Endpoint to retrieve a paginated responses of Calendar entities.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/calendars" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/calendars");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": [
        {
            "type": "calendar",
            "id": "25",
            "attributes": {
                "name": "example name",
                "category": "bin_product_calendar",
                "from": "2020-01-01T00:00:00.000000Z",
                "until": "2020-12-31T00:00:00.000000Z",
                "properties": [],
                "created_at": "2020-08-07T09:24:04.000000Z",
                "updated_at": "2020-08-07T09:24:04.000000Z"
            },
            "relationships": {
                "collector": {
                    "data": {
                        "type": "option",
                        "id": "8211"
                    }
                }
            }
        }
    ],
    "included": [
        {
            "type": "option",
            "id": "8211",
            "attributes": {
                "category": "calendar_collector",
                "name": "Fungo",
                "created_at": "2020-08-07T09:00:06.000000Z",
                "updated_at": "2020-08-07T09:00:06.000000Z"
            }
        }
    ],
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/calendars?include=collector%2Cdates&page=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/calendars?include=collector%2Cdates&page=1",
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/calendars?include=collector%2Cdates&page=1"
    }
}

Example response (204):

[]

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/calendars

POST Calendar


Requires authentication

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v2/calendars" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/calendars");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "data": {
        "type": "calendar",
        "id": "107",
        "attributes": {
            "name": "Example name",
            "category": "bin_product_calendar",
            "from": "2020-01-01T00:00:00.000000Z",
            "until": "2020-12-31T00:00:00.000000Z",
            "properties": [],
            "created_at": "2020-08-26T09:25:02.000000Z",
            "updated_at": "2020-08-26T09:25:02.000000Z"
        },
        "relationships": {
            "children": {
                "data": [
                    {
                        "type": "calendar",
                        "id": "108"
                    }
                ]
            },
            "collector": {
                "data": {
                    "type": "option",
                    "id": "8220"
                }
            },
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": "12731"
                    },
                    {
                        "type": "profile",
                        "id": "12732"
                    }
                ]
            },
            "geo-locations": {
                "data": [
                    {
                        "type": "geo-location",
                        "id": "10788"
                    },
                    {
                        "type": "geo-location",
                        "id": "10789"
                    },
                    {
                        "type": "geo-location",
                        "id": "10790"
                    }
                ]
            }
        }
    },
    "included": [
        {
            "type": "calendar-date",
            "id": "202",
            "attributes": {
                "date": "2020-01-01T00:00:00.000000Z",
                "created_at": "2020-08-26T09:25:02.000000Z",
                "updated_at": "2020-08-26T09:25:02.000000Z"
            }
        },
        {
            "type": "calendar-date",
            "id": "203",
            "attributes": {
                "date": "2020-01-11T00:00:00.000000Z",
                "created_at": "2020-08-26T09:25:02.000000Z",
                "updated_at": "2020-08-26T09:25:02.000000Z"
            }
        },
        {
            "type": "calendar-date",
            "id": "204",
            "attributes": {
                "date": "2020-01-21T00:00:00.000000Z",
                "created_at": "2020-08-26T09:25:02.000000Z",
                "updated_at": "2020-08-26T09:25:02.000000Z"
            }
        },
        {
            "type": "calendar-date",
            "id": "205",
            "attributes": {
                "date": "2020-01-31T00:00:00.000000Z",
                "created_at": "2020-08-26T09:25:02.000000Z",
                "updated_at": "2020-08-26T09:25:02.000000Z"
            }
        },
        {
            "type": "calendar",
            "id": "108",
            "attributes": {
                "name": "Example name - child route",
                "category": "bin_product_sub_calendar",
                "from": "2020-08-26T09:25:02.711944Z",
                "until": "2020-08-26T09:25:02.711953Z",
                "properties": {
                    "every_x_weeks": 2,
                    "first_emptying_date": "2020-01-01"
                },
                "created_at": "2020-08-26T09:25:02.000000Z",
                "updated_at": "2020-08-26T09:25:02.000000Z"
            },
            "relationships": {
                "dates": {
                    "data": [
                        {
                            "type": "calendar-date",
                            "id": "202"
                        },
                        {
                            "type": "calendar-date",
                            "id": "203"
                        },
                        {
                            "type": "calendar-date",
                            "id": "204"
                        },
                        {
                            "type": "calendar-date",
                            "id": "205"
                        }
                    ]
                }
            }
        },
        {
            "type": "option",
            "id": "8220",
            "attributes": {
                "category": "calendar_collector",
                "name": "qui",
                "created_at": "2020-08-26T09:25:02.000000Z",
                "updated_at": "2020-08-26T09:25:02.000000Z"
            }
        },
        {
            "type": "profile",
            "id": "12731",
            "attributes": {
                "category": "bin_product_profile",
                "properties": [],
                "external_id": null
            }
        },
        {
            "type": "profile",
            "id": "12732",
            "attributes": {
                "category": "bin_product_profile",
                "properties": [],
                "external_id": null
            }
        },
        {
            "type": "geo-location",
            "id": "10788",
            "attributes": {
                "category": "city_geo_location",
                "name": null,
                "code": null,
                "external_id": null,
                "created_at": "2020-08-26T09:25:02.000000Z",
                "updated_at": "2020-08-26T09:25:02.000000Z"
            }
        },
        {
            "type": "geo-location",
            "id": "10789",
            "attributes": {
                "category": "city_geo_location",
                "name": null,
                "code": null,
                "external_id": null,
                "created_at": "2020-08-26T09:25:02.000000Z",
                "updated_at": "2020-08-26T09:25:02.000000Z"
            }
        },
        {
            "type": "geo-location",
            "id": "10790",
            "attributes": {
                "category": "city_geo_location",
                "name": null,
                "code": null,
                "external_id": null,
                "created_at": "2020-08-26T09:25:02.000000Z",
                "updated_at": "2020-08-26T09:25:02.000000Z"
            }
        }
    ]
}

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

POST api/v2/calendars

GET Calendar


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/calendars/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/calendars/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": null,
        "id": "2678",
        "attributes": {
            "name": "ut",
            "category": "bin_product_calendar",
            "from": "2019-09-07T00:00:00.000000Z",
            "until": "2021-03-08T00:00:00.000000Z",
            "properties": [],
            "created_at": "2020-08-26T14:31:22.000000Z",
            "updated_at": "2020-08-26T14:31:22.000000Z"
        },
        "relationships": {
            "children": {
                "data": [
                    {
                        "type": "calendar",
                        "id": "2679"
                    }
                ]
            },
            "profiles": {
                "data": [
                    {
                        "type": "profile",
                        "id": "13929"
                    },
                    {
                        "type": "profile",
                        "id": "13930"
                    }
                ]
            },
            "geo-locations": {
                "data": [
                    {
                        "type": "geo-location",
                        "id": "13111"
                    },
                    {
                        "type": "geo-location",
                        "id": "13112"
                    },
                    {
                        "type": "geo-location",
                        "id": "13113"
                    },
                    {
                        "type": "geo-location",
                        "id": "13114"
                    },
                    {
                        "type": "geo-location",
                        "id": "13115"
                    },
                    {
                        "type": "geo-location",
                        "id": "13116"
                    }
                ]
            }
        }
    },
    "included": [
        {
            "type": "calendar",
            "id": "2679",
            "attributes": {
                "name": "quis",
                "category": "bin_product_calendar",
                "from": "2019-08-31T00:00:00.000000Z",
                "until": "2021-02-06T00:00:00.000000Z",
                "properties": [],
                "created_at": "2020-08-26T14:31:22.000000Z",
                "updated_at": "2020-08-26T14:31:22.000000Z"
            }
        },
        {
            "type": "profile",
            "id": "13929",
            "attributes": {
                "category": "bin_product_profile",
                "properties": [],
                "external_id": null
            }
        },
        {
            "type": "profile",
            "id": "13930",
            "attributes": {
                "category": "bin_product_profile",
                "properties": [],
                "external_id": null
            }
        },
        {
            "type": "geo-location",
            "id": "13111",
            "attributes": {
                "category": "city_geo_location",
                "name": null,
                "code": null,
                "external_id": null,
                "created_at": "2020-08-26T14:31:22.000000Z",
                "updated_at": "2020-08-26T14:31:22.000000Z"
            }
        },
        {
            "type": "geo-location",
            "id": "13112",
            "attributes": {
                "category": "city_geo_location",
                "name": null,
                "code": null,
                "external_id": null,
                "created_at": "2020-08-26T14:31:22.000000Z",
                "updated_at": "2020-08-26T14:31:22.000000Z"
            }
        },
        {
            "type": "geo-location",
            "id": "13113",
            "attributes": {
                "category": "city_geo_location",
                "name": null,
                "code": null,
                "external_id": null,
                "created_at": "2020-08-26T14:31:22.000000Z",
                "updated_at": "2020-08-26T14:31:22.000000Z"
            }
        },
        {
            "type": "geo-location",
            "id": "13114",
            "attributes": {
                "category": "city_geo_location",
                "name": null,
                "code": null,
                "external_id": null,
                "created_at": "2020-08-26T14:31:22.000000Z",
                "updated_at": "2020-08-26T14:31:22.000000Z"
            }
        },
        {
            "type": "geo-location",
            "id": "13115",
            "attributes": {
                "category": "city_geo_location",
                "name": null,
                "code": null,
                "external_id": null,
                "created_at": "2020-08-26T14:31:22.000000Z",
                "updated_at": "2020-08-26T14:31:22.000000Z"
            }
        },
        {
            "type": "geo-location",
            "id": "13116",
            "attributes": {
                "category": "city_geo_location",
                "name": null,
                "code": null,
                "external_id": null,
                "created_at": "2020-08-26T14:31:22.000000Z",
                "updated_at": "2020-08-26T14:31:22.000000Z"
            }
        }
    ]
}

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/calendars/{calendar}

DELETE Calendar


Requires authentication

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v2/calendars/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/calendars/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v2/calendars/{calendar}

PATCH Calendar


Requires authentication

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v2/calendars/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/calendars/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "PATCH",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "calendar",
        "id": "207",
        "attributes": {
            "name": "dolorem",
            "category": "bin_product_calendar",
            "from": "2020-01-01T00:00:00.000000Z",
            "until": "2020-12-31T00:00:00.000000Z",
            "properties": [],
            "created_at": "2020-09-04T11:13:40.000000Z",
            "updated_at": "2020-09-04T11:13:40.000000Z"
        }
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The data.id field is required."
        ],
        "data.type": [
            "The data.type field is required."
        ],
        "data.attributes": [
            "The data.attributes field must be present."
        ]
    }
}

HTTP Request

PATCH api/v2/calendars/{calendar}

V2/Persons

API V2 endpoint for retrieving and managing Person entities.

GET index


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/persons" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/persons");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": [
        {
            "type": "person",
            "id": "6017524",
            "attributes": {
                "category": "company_contact_person",
                "link_id": 1,
                "role": null,
                "first_name": "JOHN",
                "last_name": "DOE",
                "salutation": null,
                "phone": "123456",
                "fax": null,
                "mobile": "",
                "email": "jogn.doe@inovim.eu",
                "identification_number": null,
                "company_name": null,
                "vat": null,
                "gender": null,
                "bic": null,
                "date_of_birth": null,
                "external_id": null,
                "properties": {
                    "function": "Gestionnaire",
                    "authorized_signatory": null,
                    "memo": null
                },
                "language": "nl",
                "created_at": "2021-05-18 09:57:26",
                "updated_at": "2021-05-21 09:57:26",
                "deleted_at": null
            }
        },
        {
            "type": "person",
            "id": "6021623",
            "attributes": {
                "category": "inhabitant_person",
                "link_id": 24185,
                "role": "Reference person",
                "first_name": "",
                "last_name": "Résidence Inovim",
                "salutation": null,
                "phone": null,
                "fax": null,
                "mobile": null,
                "email": null,
                "identification_number": null,
                "company_name": "",
                "vat": null,
                "gender": null,
                "bic": null,
                "date_of_birth": null,
                "external_id": "930",
                "properties": [],
                "language": "nl",
                "created_at": "2021-04-08 05:50:30",
                "updated_at": "2021-04-08 05:50:30",
                "deleted_at": null
            },
            "relationships": {
                "pois": {
                    "data": [
                        {
                            "type": "poi",
                            "id": "6755584"
                        }
                    ]
                }
            }
        }
    ],
    "included": [
        {
            "type": "poi",
            "id": "6755584",
            "attributes": {
                "category": "residential_poi",
                "link_id": 37081,
                "alias": "1921 Avenue Inovim, G1E4A2 Aalst",
                "zipcode": "G1E4A2",
                "number": "1921",
                "letter": "",
                "addition": "",
                "latitude": "46.84938000",
                "longitude": "-71.20798300",
                "properties": {
                    "property_id": "124941",
                    "stime_id": "920"
                },
                "external_id": "34800",
                "created_at": "2021-08-10 08:38:40",
                "updated_at": "2021-10-07 04:57:24",
                "deleted_at": null
            }
        }
    ],
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 2,
            "from": 1,
            "to": 2,
            "total": 4140,
            "last_page": 2070
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/persons?include=pois&page%5Bsize%5D=2&page=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/persons?include=pois&page%5Bsize%5D=2&page=1",
        "next": "https:\/\/api.ci-web.eu\/api\/v2\/persons?include=pois&page%5Bsize%5D=2&page=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/persons?include=pois&page%5Bsize%5D=2&page=2070"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/persons

GET show


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/persons/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/persons/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "person",
        "id": "6021623",
        "attributes": {
            "category": "inhabitant_person",
            "link_id": 24185,
            "role": "Reference person",
            "first_name": "",
            "last_name": "Résidence Inovim",
            "salutation": null,
            "phone": null,
            "fax": null,
            "mobile": null,
            "email": null,
            "identification_number": null,
            "company_name": "",
            "vat": null,
            "gender": null,
            "bic": null,
            "date_of_birth": null,
            "external_id": "930",
            "properties": [],
            "language": "nl",
            "created_at": "2021-04-08 05:50:30",
            "updated_at": "2021-04-08 05:50:30",
            "deleted_at": null
        },
        "relationships": {
            "pois": {
                "data": [
                    {
                        "type": "poi",
                        "id": "6755584"
                    }
                ]
            }
        }
    },
    "included": [
        {
            "type": "poi",
            "id": "6755584",
            "attributes": {
                "category": "residential_poi",
                "link_id": 37091,
                "alias": "2404 Avenue Inovim, G1E1E8 Aalst",
                "zipcode": "G1E1E8",
                "number": "2404",
                "letter": "",
                "addition": "",
                "latitude": "46.85401200",
                "longitude": "-71.21667100",
                "properties": {
                    "property_id": "106686",
                    "stime_id": "930"
                },
                "external_id": "28671",
                "created_at": "2021-08-10 08:38:40",
                "updated_at": "2021-10-07 04:57:25",
                "deleted_at": null
            }
        }
    ]
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/persons/{person}

V2/PoiRelatedPois

API V2 endpoint for retrieving and managing PoiRelatedPoi entities.

GET index


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/poi-related-pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/poi-related-pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": [
        {
            "type": "poi-related-poi",
            "id": "3194",
            "attributes": {
                "category": "collect_poi",
                "from": null,
                "until": null,
                "repeat": null,
                "properties": {
                    "collect_poi": {
                        "memo": null,
                        "access": {
                            "key": {
                                "required": false
                            },
                            "code": {
                                "required": false,
                                "value": null
                            },
                            "memo": null
                        }
                    }
                },
                "created_at": "2020-07-22T20:00:08.000000Z",
                "updated_at": "2021-01-07T14:36:19.000000Z"
            },
            "relationships": {
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": "6746972"
                    }
                },
                "related-poi": {
                    "data": {
                        "type": "poi",
                        "id": "6750846"
                    }
                }
            }
        }
    ],
    "included": [
        {
            "type": "poi",
            "id": "6746972",
            "attributes": {
                "category": "residential_poi",
                "alias": "1 Boulevard Henri-Bourassa, K8F 8J9 Beauport",
                "zipcode": "K8F 8J9",
                "number": "1",
                "letter": "",
                "addition": "",
                "latitude": 46.837472,
                "longitude": -71.196252,
                "properties": [],
                "external_id": "200865",
                "created_at": "2020-07-22T15:13:48.000000Z",
                "updated_at": "2021-05-03T10:17:05.000000Z",
                "deleted_at": null
            }
        },
        {
            "type": "poi",
            "id": "6750846",
            "attributes": {
                "category": "collect_poi",
                "alias": null,
                "zipcode": "",
                "number": null,
                "letter": null,
                "addition": null,
                "latitude": "46.83634600",
                "longitude": "-71.20342849",
                "properties": [],
                "external_id": null,
                "created_at": "2021-01-07T14:33:18.000000Z",
                "updated_at": "2021-05-03T10:18:14.000000Z",
                "deleted_at": null
            }
        }
    ],
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 1,
            "from": 1,
            "to": 1,
            "total": 4044,
            "last_page": 4044
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/poi-related-pois?include=poi%2Crelated-poi&page%5Bsize%5D=1&page=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/poi-related-pois?include=poi%2Crelated-poi&page%5Bsize%5D=1&page=1",
        "next": "https:\/\/api.ci-web.eu\/api\/v2\/poi-related-pois?include=poi%2Crelated-poi&page%5Bsize%5D=1&page=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/poi-related-pois?include=poi%2Crelated-poi&page%5Bsize%5D=1&page=4044"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/poi-related-pois

GET show


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/poi-related-pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/poi-related-pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "poi-related-poi",
        "id": "3194",
        "attributes": {
            "category": "collect_poi",
            "from": null,
            "until": null,
            "repeat": null,
            "properties": {
                "collect_poi": {
                    "memo": null,
                    "access": {
                        "key": {
                            "required": false
                        },
                        "code": {
                            "required": false,
                            "value": null
                        },
                        "memo": null
                    }
                }
            },
            "created_at": "2020-07-22T20:00:08.000000Z",
            "updated_at": "2021-01-07T14:36:19.000000Z"
        },
        "relationships": {
            "poi": {
                "data": {
                    "type": "poi",
                    "id": "6746972"
                }
            },
            "related-poi": {
                "data": {
                    "type": "poi",
                    "id": "6750846"
                }
            }
        }
    },
    "included": [
        {
            "type": "poi",
            "id": "6746972",
            "attributes": {
                "category": "residential_poi",
                "alias": "1 Boulevard Henri-Bourassa, K8F 8J9 Beauport",
                "zipcode": "K8F 8J9",
                "number": "1",
                "letter": "",
                "addition": "",
                "latitude": 46.837472,
                "longitude": -71.196252,
                "properties": [],
                "external_id": "200865",
                "created_at": "2020-07-22T15:13:48.000000Z",
                "updated_at": "2021-05-03T10:17:05.000000Z",
                "deleted_at": null
            }
        },
        {
            "type": "poi",
            "id": "6750846",
            "attributes": {
                "category": "collect_poi",
                "alias": null,
                "zipcode": "",
                "number": null,
                "letter": null,
                "addition": null,
                "latitude": "46.83634600",
                "longitude": "-71.20342849",
                "properties": [],
                "external_id": null,
                "created_at": "2021-01-07T14:33:18.000000Z",
                "updated_at": "2021-05-03T10:18:14.000000Z",
                "deleted_at": null
            }
        }
    ]
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/poi-related-pois/{poiRelatedPoi}

V2/Pois

API V2 endpoint for retrieving and managing Poi entities.

GET index


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": [
        {
            "type": "poi",
            "id": "2966",
            "attributes": {
                "category": "collect_poi",
                "alias": " Rue Adjutor-Rivard,  La Cité-Limoilou",
                "zipcode": "",
                "number": null,
                "letter": null,
                "addition": null,
                "latitude": "46.84434213",
                "longitude": "-71.22301253",
                "properties": [],
                "external_id": null,
                "created_at": "2019-12-09T09:54:35.000000Z",
                "updated_at": "2021-05-03T10:17:01.000000Z"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "geo-location": {
                    "data": {
                        "type": "geo-location",
                        "id": "1839"
                    }
                }
            }
        },
        {
            "type": "poi",
            "id": "2967",
            "attributes": {
                "category": "collect_poi",
                "alias": " Avenue Monseigneur-Gosselin,  La Cité-Limoilou",
                "zipcode": "",
                "number": null,
                "letter": null,
                "addition": null,
                "latitude": "46.84598684",
                "longitude": "-71.22610394",
                "properties": [],
                "external_id": null,
                "created_at": "2019-12-09T10:01:33.000000Z",
                "updated_at": "2021-05-03T10:17:01.000000Z"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "geo-location": {
                    "data": {
                        "type": "geo-location",
                        "id": "1758"
                    }
                }
            }
        }
    ],
    "included": [
        {
            "type": "customer",
            "id": "1",
            "attributes": {
                "category": "project_customer",
                "customer_key": "quebec",
                "name": "Ville de Quebec",
                "key_code": "quebec",
                "description": "demo Quebec",
                "active": true
            }
        },
        {
            "type": "geo-location",
            "id": "1839",
            "attributes": {
                "category": "street_geo_location",
                "name": "Rue Adjutor-Rivard",
                "code": null,
                "external_id": null,
                "created_at": "2020-03-31T08:30:03.000000Z",
                "updated_at": "2021-05-05T12:15:33.000000Z"
            }
        },
        {
            "type": "geo-location",
            "id": "1758",
            "attributes": {
                "category": "street_geo_location",
                "name": "Avenue Monseigneur-Gosselin",
                "code": null,
                "external_id": null,
                "created_at": "2020-03-31T08:30:03.000000Z",
                "updated_at": "2021-05-05T12:15:32.000000Z"
            }
        }
    ],
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 2,
            "from": 1,
            "to": 2,
            "total": 4140,
            "last_page": 2070
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/pois?include=customer%2Cgeo-location%2Cproducts%2Cevents%2Cprofiles&page%5Bsize%5D=2&page=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/pois?include=customer%2Cgeo-location%2Cproducts%2Cevents%2Cprofiles&page%5Bsize%5D=2&page=1",
        "next": "https:\/\/api.ci-web.eu\/api\/v2\/pois?include=customer%2Cgeo-location%2Cproducts%2Cevents%2Cprofiles&page%5Bsize%5D=2&page=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/pois?include=customer%2Cgeo-location%2Cproducts%2Cevents%2Cprofiles&page%5Bsize%5D=2&page=2070"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/pois

GET show


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "poi",
        "id": "2966",
        "attributes": {
            "category": "collect_poi",
            "alias": " Rue Adjutor-Rivard,  La Cité-Limoilou",
            "zipcode": "",
            "number": null,
            "letter": null,
            "addition": null,
            "latitude": "46.84434213",
            "longitude": "-71.22301253",
            "properties": [],
            "external_id": null,
            "created_at": "2019-12-09T09:54:35.000000Z",
            "updated_at": "2021-05-03T10:17:01.000000Z"
        },
        "relationships": {
            "customer": {
                "data": {
                    "type": "customer",
                    "id": "1"
                }
            },
            "geo-location": {
                "data": {
                    "type": "geo-location",
                    "id": "1839"
                }
            }
        }
    },
    "included": [
        {
            "type": "customer",
            "id": "1",
            "attributes": {
                "category": "project_customer",
                "customer_key": "quebec",
                "name": "Ville de Quebec",
                "key_code": "quebec",
                "description": "demo Quebec",
                "active": true
            }
        },
        {
            "type": "geo-location",
            "id": "1839",
            "attributes": {
                "category": "street_geo_location",
                "name": "Rue Adjutor-Rivard",
                "code": null,
                "external_id": null,
                "created_at": "2020-03-31T08:30:03.000000Z",
                "updated_at": "2021-05-05T12:15:33.000000Z"
            }
        }
    ]
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/pois/{poi}

V2/ProductRelatedPois

API V2 endpoint for retrieving and managing ProductRelatedPoi entities.

GET Index


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/product-related-pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/product-related-pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": [
        {
            "type": "product-related-poi",
            "id": "43125",
            "attributes": {
                "category": "collect_poi",
                "from": "2021-02-01T00:00:00+00:00",
                "until": "2021-02-26T00:00:00+00:00",
                "repeat": null,
                "properties": [],
                "created_at": "2021-02-01T16:17:51.000000Z",
                "updated_at": "2021-05-03T06:02:11.000000Z",
                "poi_alias": null
            },
            "relationships": {
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": "6750848"
                    }
                },
                "product": {
                    "data": {
                        "type": "product",
                        "id": "14778657"
                    }
                }
            }
        },
        {
            "type": "product-related-poi",
            "id": "43126",
            "attributes": {
                "category": "collect_poi",
                "from": "2021-02-01T00:00:00+00:00",
                "until": "2021-02-26T00:00:00+00:00",
                "repeat": null,
                "properties": null,
                "created_at": "2021-02-01T16:18:54.000000Z",
                "updated_at": "2021-02-01T16:18:54.000000Z",
                "poi_alias": null
            },
            "relationships": {
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": "6750849"
                    }
                },
                "product": {
                    "data": {
                        "type": "product",
                        "id": "14778657"
                    }
                }
            }
        }
    ],
    "included": [
        {
            "type": "poi",
            "id": "6750848",
            "attributes": {
                "category": "collect_poi",
                "alias": null,
                "zipcode": "",
                "number": null,
                "letter": null,
                "addition": null,
                "latitude": "46.85833406",
                "longitude": "-71.19190515",
                "properties": [],
                "external_id": null,
                "created_at": "2021-02-01T16:17:51.000000Z",
                "updated_at": "2021-05-03T10:18:14.000000Z",
                "deleted_at": null
            }
        },
        {
            "type": "product",
            "id": "14778657",
            "attributes": {
                "category": "bin_product",
                "chipcode": null,
                "barcode": null,
                "label_code": "80575",
                "container_code": "",
                "properties": [],
                "external_id": "77901"
            }
        },
        {
            "type": "poi",
            "id": "6750849",
            "attributes": {
                "category": "collect_poi",
                "alias": null,
                "zipcode": "",
                "number": null,
                "letter": null,
                "addition": null,
                "latitude": "46.85853381",
                "longitude": "-71.19271533",
                "properties": [],
                "external_id": null,
                "created_at": "2021-02-01T16:18:53.000000Z",
                "updated_at": "2021-05-03T10:18:14.000000Z",
                "deleted_at": null
            }
        }
    ],
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 2,
            "total": 2,
            "last_page": 1
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/product-related-pois?append=poi_alias&filter%5Bcategory%5D=collect_poi&filter%5Bid%5D=43125%2C43126&include=product%2Cpoi&page=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/product-related-pois?append=poi_alias&filter%5Bcategory%5D=collect_poi&filter%5Bid%5D=43125%2C43126&include=product%2Cpoi&page=1",
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/product-related-pois?append=poi_alias&filter%5Bcategory%5D=collect_poi&filter%5Bid%5D=43125%2C43126&include=product%2Cpoi&page=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/product-related-pois

GET show


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/product-related-pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/product-related-pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "product-related-poi",
        "id": "43126",
        "attributes": {
            "category": "collect_poi",
            "from": "2021-02-01T00:00:00+00:00",
            "until": "2021-02-26T00:00:00+00:00",
            "repeat": null,
            "properties": null,
            "created_at": "2021-02-01T16:18:54.000000Z",
            "updated_at": "2021-02-01T16:18:54.000000Z",
            "poi_alias": null
        },
        "relationships": {
            "product": {
                "data": {
                    "type": "product",
                    "id": "14778657"
                }
            }
        }
    },
    "included": [
        {
            "type": "product",
            "id": "14778657",
            "attributes": {
                "category": "bin_product",
                "chipcode": null,
                "barcode": null,
                "label_code": "80575",
                "container_code": "",
                "properties": [],
                "external_id": "77901"
            }
        }
    ]
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/product-related-pois/{productRelatedPoi}

V3/Products

Api calls for managing the Product entity.

GET index


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v3/products" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v3/products");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": [
        {
            "type": "product",
            "id": "14776227",
            "attributes": {
                "category": "bin_product",
                "chipcode": null,
                "barcode": null,
                "label_code": null,
                "container_code": "",
                "properties": {
                    "memo": null,
                    "bin_product_wheels": 605739,
                    "bin_product_wheels_size": 605799,
                    "bin_product_chute_a_matiere": 605798,
                    "bin_product_compacted": 605804,
                    "bin_product_owner": 605806,
                    "bin_product_waste_precision": 605810,
                    "next_emptying": "2021-07-06",
                    "next_emptying_by_fraction": [
                        {
                            "date": "2021-07-06",
                            "fraction": "Déchets",
                            "contract": {
                                "every_x_weeks": 1,
                                "frequency": 2,
                                "supported_days": [
                                    "Tuesday",
                                    "Friday"
                                ]
                            }
                        }
                    ]
                },
                "external_id": "52486",
                "alias": "CCAv 2vc Déchets CCAV"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": "30441483"
                        }
                    ]
                }
            }
        },
        {
            "type": "product",
            "id": "14776228",
            "attributes": {
                "category": "bin_product",
                "chipcode": "BAC800003383",
                "barcode": null,
                "label_code": "23277",
                "container_code": "",
                "properties": {
                    "memo": null,
                    "bin_product_wheels": 605739,
                    "bin_product_wheels_size": 605799,
                    "bin_product_chute_a_matiere": 605798,
                    "bin_product_compacted": 605804,
                    "bin_product_owner": 605806,
                    "bin_product_waste_precision": 605810,
                    "next_emptying": "2021-07-06",
                    "next_emptying_by_fraction": [
                        {
                            "date": "2021-07-06",
                            "fraction": "Déchets",
                            "contract": {
                                "every_x_weeks": 1,
                                "frequency": 2,
                                "supported_days": [
                                    "Tuesday",
                                    "Friday"
                                ]
                            }
                        }
                    ]
                },
                "external_id": "39208",
                "alias": "CCAv 2vc Déchets CCAV"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": "30441484"
                        }
                    ]
                }
            }
        },
        {
            "type": "product",
            "id": "14776229",
            "attributes": {
                "category": "bin_product",
                "chipcode": "BAC800003455",
                "barcode": null,
                "label_code": "02-0-0981 (1297)",
                "container_code": "",
                "properties": {
                    "memo": null,
                    "bin_product_wheels": 605739,
                    "bin_product_wheels_size": 605799,
                    "bin_product_chute_a_matiere": 605798,
                    "bin_product_compacted": 605804,
                    "bin_product_owner": 605806,
                    "bin_product_waste_precision": 605810,
                    "next_emptying": "2021-07-06",
                    "next_emptying_by_fraction": [
                        {
                            "date": "2021-07-06",
                            "fraction": "Déchets",
                            "contract": {
                                "every_x_weeks": 1,
                                "frequency": 2,
                                "supported_days": [
                                    "Tuesday",
                                    "Friday"
                                ]
                            }
                        }
                    ]
                },
                "external_id": "69347",
                "alias": "CCAv 2vc Déchets CCAV"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": "30442676"
                        }
                    ]
                }
            }
        },
        {
            "type": "product",
            "id": "14776230",
            "attributes": {
                "category": "bin_product",
                "chipcode": "BAC800003954",
                "barcode": null,
                "label_code": "23303",
                "container_code": "",
                "properties": {
                    "bin_product_chute_a_matiere": 605798,
                    "bin_product_compacted": 605804,
                    "bin_product_owner": 605806,
                    "bin_product_waste_precision": 605810,
                    "bin_product_wheels": 605739,
                    "bin_product_wheels_size": 605799,
                    "memo": null,
                    "next_emptying": "2021-07-05",
                    "next_emptying_by_fraction": [
                        {
                            "date": "2021-07-05",
                            "fraction": "Déchets",
                            "contract": {
                                "every_x_weeks": 1,
                                "frequency": 2,
                                "supported_days": [
                                    "Monday",
                                    "Thursday"
                                ]
                            }
                        }
                    ]
                },
                "external_id": "28969",
                "alias": "CCAv 2vc Déchets CCAV"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": "30442233"
                        }
                    ]
                }
            }
        },
        {
            "type": "product",
            "id": "14776231",
            "attributes": {
                "category": "bin_product",
                "chipcode": "BAC800000477",
                "barcode": null,
                "label_code": null,
                "container_code": "",
                "properties": {
                    "memo": null,
                    "bin_product_wheels": 605739,
                    "bin_product_wheels_size": 605799,
                    "bin_product_chute_a_matiere": 605798,
                    "bin_product_compacted": 605804,
                    "bin_product_owner": 605806,
                    "bin_product_waste_precision": 605810,
                    "next_emptying": null,
                    "next_emptying_by_fraction": []
                },
                "external_id": "39966",
                "alias": "CCAv 2vc Déchets CCAV"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": "30441599"
                        }
                    ]
                }
            }
        },
        {
            "type": "product",
            "id": "14776232",
            "attributes": {
                "category": "bin_product",
                "chipcode": "BAC800003454",
                "barcode": null,
                "label_code": "02-01141 (1277) ",
                "container_code": "",
                "properties": {
                    "memo": null,
                    "bin_product_wheels": 605739,
                    "bin_product_wheels_size": 605799,
                    "bin_product_chute_a_matiere": 605798,
                    "bin_product_compacted": 605804,
                    "bin_product_owner": 605806,
                    "bin_product_waste_precision": 605810,
                    "next_emptying": "2021-07-06",
                    "next_emptying_by_fraction": [
                        {
                            "date": "2021-07-06",
                            "fraction": "Déchets",
                            "contract": {
                                "every_x_weeks": 1,
                                "frequency": 2,
                                "supported_days": [
                                    "Tuesday",
                                    "Friday"
                                ]
                            }
                        }
                    ]
                },
                "external_id": "27165",
                "alias": "CCAv 2vc Déchets CCAV"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": "30442677"
                        }
                    ]
                }
            }
        },
        {
            "type": "product",
            "id": "14776233",
            "attributes": {
                "category": "bin_product",
                "chipcode": "BAC800000467",
                "barcode": null,
                "label_code": null,
                "container_code": "",
                "properties": {
                    "memo": null,
                    "bin_product_wheels": 605739,
                    "bin_product_wheels_size": 605799,
                    "bin_product_chute_a_matiere": 605798,
                    "bin_product_compacted": 605804,
                    "bin_product_owner": 605806,
                    "bin_product_waste_precision": 605810,
                    "next_emptying": null,
                    "next_emptying_by_fraction": []
                },
                "external_id": "57467",
                "alias": "CCAv 2vc Déchets CCAV"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": "30441600"
                        }
                    ]
                }
            }
        },
        {
            "type": "product",
            "id": "14776234",
            "attributes": {
                "category": "bin_product",
                "chipcode": "BAC800000441",
                "barcode": null,
                "label_code": "201706",
                "container_code": "",
                "properties": {
                    "memo": null,
                    "bin_product_wheels": 605739,
                    "bin_product_wheels_size": 605799,
                    "bin_product_chute_a_matiere": 605798,
                    "bin_product_compacted": 605804,
                    "bin_product_owner": 605806,
                    "bin_product_waste_precision": 605810,
                    "next_emptying": null,
                    "next_emptying_by_fraction": []
                },
                "external_id": "79355",
                "alias": "CCAv 2vc Déchets CCAV"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": "30441601"
                        }
                    ]
                }
            }
        },
        {
            "type": "product",
            "id": "14776235",
            "attributes": {
                "category": "bin_product",
                "chipcode": "BAC800000356",
                "barcode": null,
                "label_code": null,
                "container_code": "",
                "properties": {
                    "memo": null,
                    "bin_product_wheels": 605739,
                    "bin_product_wheels_size": 605799,
                    "bin_product_chute_a_matiere": 605798,
                    "bin_product_compacted": 605804,
                    "bin_product_owner": 605806,
                    "bin_product_waste_precision": 605810,
                    "next_emptying": "2021-07-05",
                    "next_emptying_by_fraction": [
                        {
                            "date": "2021-07-05",
                            "fraction": "Déchets",
                            "contract": {
                                "every_x_weeks": 1,
                                "frequency": 1,
                                "supported_days": [
                                    "Monday"
                                ]
                            }
                        }
                    ]
                },
                "external_id": "88550",
                "alias": "CCAv 2vc Déchets CCAV"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": "30441602"
                        }
                    ]
                }
            }
        },
        {
            "type": "product",
            "id": "14776236",
            "attributes": {
                "category": "bin_product",
                "chipcode": "BAC800002764",
                "barcode": null,
                "label_code": "20255",
                "container_code": "",
                "properties": {
                    "memo": null,
                    "bin_product_wheels": 605739,
                    "bin_product_wheels_size": 605799,
                    "bin_product_chute_a_matiere": 605798,
                    "bin_product_compacted": 605804,
                    "bin_product_owner": 605806,
                    "bin_product_waste_precision": 605810,
                    "next_emptying": "2021-07-05",
                    "next_emptying_by_fraction": [
                        {
                            "date": "2021-07-05",
                            "fraction": "Déchets",
                            "contract": {
                                "every_x_weeks": 1,
                                "frequency": 2,
                                "supported_days": [
                                    "Monday",
                                    "Thursday"
                                ]
                            }
                        }
                    ]
                },
                "external_id": "54862",
                "alias": "CCAv 2vc Déchets CCAV"
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": "1"
                    }
                },
                "events": {
                    "data": [
                        {
                            "type": "event",
                            "id": "30441241"
                        }
                    ]
                }
            }
        }
    ],
    "included": [
        {
            "type": "customer",
            "id": "1",
            "attributes": {
                "category": "project_customer",
                "customer_key": "quebec",
                "name": "Ville de Quebec",
                "key_code": "quebec",
                "description": "demo Quebec",
                "active": true
            }
        },
        {
            "type": "event",
            "id": "30441483",
            "attributes": {
                "category": "action_event",
                "properties": {
                    "outside_zone": false
                },
                "external_id": null,
                "created_at": "2020-07-23T14:42:00.000000Z",
                "updated_at": "2021-08-05T11:28:38.000000Z"
            }
        },
        {
            "type": "event",
            "id": "30441484",
            "attributes": {
                "category": "action_event",
                "properties": {
                    "outside_zone": false
                },
                "external_id": null,
                "created_at": "2020-07-23T14:42:00.000000Z",
                "updated_at": "2021-08-05T11:28:38.000000Z"
            }
        },
        {
            "type": "event",
            "id": "30442676",
            "attributes": {
                "category": "action_event",
                "properties": {
                    "outside_zone": false
                },
                "external_id": null,
                "created_at": "2020-07-23T14:42:00.000000Z",
                "updated_at": "2021-08-05T11:28:38.000000Z"
            }
        },
        {
            "type": "event",
            "id": "30442233",
            "attributes": {
                "category": "action_event",
                "properties": {
                    "outside_zone": false
                },
                "external_id": null,
                "created_at": "2020-07-23T14:42:00.000000Z",
                "updated_at": "2021-08-05T11:28:38.000000Z"
            }
        },
        {
            "type": "event",
            "id": "30441599",
            "attributes": {
                "category": "action_event",
                "properties": {
                    "outside_zone": false
                },
                "external_id": null,
                "created_at": "2020-07-23T14:42:00.000000Z",
                "updated_at": "2021-08-05T11:28:38.000000Z"
            }
        },
        {
            "type": "event",
            "id": "30442677",
            "attributes": {
                "category": "action_event",
                "properties": {
                    "outside_zone": false
                },
                "external_id": null,
                "created_at": "2020-07-23T14:42:00.000000Z",
                "updated_at": "2021-08-05T11:28:38.000000Z"
            }
        },
        {
            "type": "event",
            "id": "30441600",
            "attributes": {
                "category": "action_event",
                "properties": {
                    "outside_zone": false
                },
                "external_id": null,
                "created_at": "2020-07-23T14:42:00.000000Z",
                "updated_at": "2021-08-05T11:28:38.000000Z"
            }
        },
        {
            "type": "event",
            "id": "30441601",
            "attributes": {
                "category": "action_event",
                "properties": {
                    "outside_zone": false
                },
                "external_id": null,
                "created_at": "2020-07-23T14:42:00.000000Z",
                "updated_at": "2021-08-05T11:28:38.000000Z"
            }
        },
        {
            "type": "event",
            "id": "30441602",
            "attributes": {
                "category": "action_event",
                "properties": {
                    "outside_zone": false
                },
                "external_id": null,
                "created_at": "2020-07-23T14:42:00.000000Z",
                "updated_at": "2021-08-05T11:28:38.000000Z"
            }
        },
        {
            "type": "event",
            "id": "30441241",
            "attributes": {
                "category": "action_event",
                "properties": {
                    "outside_zone": false
                },
                "external_id": null,
                "created_at": "2020-07-23T14:42:00.000000Z",
                "updated_at": "2021-08-05T11:28:38.000000Z"
            }
        }
    ],
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 10,
            "from": 1,
            "to": 10,
            "total": 7232,
            "last_page": 724
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v3\/products?include=customer%2Cevents&page%5Bsize%5D=10&page=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v3\/products?include=customer%2Cevents&page%5Bsize%5D=10&page=1",
        "next": "https:\/\/api.ci-web.eu\/api\/v3\/products?include=customer%2Cevents&page%5Bsize%5D=10&page=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v3\/products?include=customer%2Cevents&page%5Bsize%5D=10&page=724"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v3/products

GET show


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v3/products/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v3/products/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": {
        "type": "product",
        "id": "14776236",
        "attributes": {
            "category": "bin_product",
            "chipcode": "BAC800002764",
            "barcode": null,
            "label_code": "20255",
            "container_code": "",
            "properties": {
                "memo": null,
                "bin_product_wheels": 605739,
                "bin_product_wheels_size": 605799,
                "bin_product_chute_a_matiere": 605798,
                "bin_product_compacted": 605804,
                "bin_product_owner": 605806,
                "bin_product_waste_precision": 605810,
                "next_emptying": "2021-07-05",
                "next_emptying_by_fraction": [
                    {
                        "date": "2021-07-05",
                        "fraction": "Déchets",
                        "contract": {
                            "every_x_weeks": 1,
                            "frequency": 2,
                            "supported_days": [
                                "Monday",
                                "Thursday"
                            ]
                        }
                    }
                ]
            },
            "external_id": "54862",
            "alias": "CCAv 2vc Déchets CCAV"
        }
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v3/products/{product}

V3/Profiles

API endpoints (V3) for managing the Profile entity.

Class ProfileController

GET Index


Requires authentication Endpoint to retrieve a paginated result of Profile entities.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v3/profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v3/profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "data": [
        {
            "type": "profile",
            "id": "12603",
            "attributes": {
                "category": "bin_product_profile",
                "properties": [],
                "external_id": null
            },
            "relationships": {
                "options": {
                    "data": [
                        {
                            "type": "option",
                            "id": "1057"
                        },
                        {
                            "type": "option",
                            "id": "1108"
                        },
                        {
                            "type": "option",
                            "id": "1110"
                        },
                        {
                            "type": "option",
                            "id": "1128"
                        },
                        {
                            "type": "option",
                            "id": "1157"
                        },
                        {
                            "type": "option",
                            "id": "1166"
                        },
                        {
                            "type": "option",
                            "id": "1169"
                        },
                        {
                            "type": "option",
                            "id": "1172"
                        },
                        {
                            "type": "option",
                            "id": "1174"
                        },
                        {
                            "type": "option",
                            "id": "1175"
                        },
                        {
                            "type": "option",
                            "id": "1177"
                        },
                        {
                            "type": "option",
                            "id": "1179"
                        },
                        {
                            "type": "option",
                            "id": "1181"
                        },
                        {
                            "type": "option",
                            "id": "1184"
                        },
                        {
                            "type": "option",
                            "id": "1185"
                        },
                        {
                            "type": "option",
                            "id": "1188"
                        }
                    ]
                }
            }
        },
        {
            "type": "profile",
            "id": "12604",
            "attributes": {
                "category": "bin_product_profile",
                "properties": [],
                "external_id": null
            },
            "relationships": {
                "options": {
                    "data": [
                        {
                            "type": "option",
                            "id": "1057"
                        },
                        {
                            "type": "option",
                            "id": "1064"
                        },
                        {
                            "type": "option",
                            "id": "1108"
                        },
                        {
                            "type": "option",
                            "id": "1110"
                        },
                        {
                            "type": "option",
                            "id": "1127"
                        },
                        {
                            "type": "option",
                            "id": "1157"
                        },
                        {
                            "type": "option",
                            "id": "1169"
                        },
                        {
                            "type": "option",
                            "id": "1172"
                        },
                        {
                            "type": "option",
                            "id": "1174"
                        },
                        {
                            "type": "option",
                            "id": "1175"
                        },
                        {
                            "type": "option",
                            "id": "1177"
                        },
                        {
                            "type": "option",
                            "id": "1179"
                        },
                        {
                            "type": "option",
                            "id": "1181"
                        },
                        {
                            "type": "option",
                            "id": "1184"
                        },
                        {
                            "type": "option",
                            "id": "1185"
                        },
                        {
                            "type": "option",
                            "id": "1188"
                        }
                    ]
                }
            }
        },
        {
            "type": "profile",
            "id": "12605",
            "attributes": {
                "category": "bin_product_profile",
                "properties": [],
                "external_id": null
            },
            "relationships": {
                "options": {
                    "data": [
                        {
                            "type": "option",
                            "id": "1057"
                        },
                        {
                            "type": "option",
                            "id": "1066"
                        },
                        {
                            "type": "option",
                            "id": "1108"
                        },
                        {
                            "type": "option",
                            "id": "1110"
                        },
                        {
                            "type": "option",
                            "id": "1129"
                        },
                        {
                            "type": "option",
                            "id": "1157"
                        },
                        {
                            "type": "option",
                            "id": "1169"
                        },
                        {
                            "type": "option",
                            "id": "1172"
                        },
                        {
                            "type": "option",
                            "id": "1174"
                        },
                        {
                            "type": "option",
                            "id": "1175"
                        },
                        {
                            "type": "option",
                            "id": "1177"
                        },
                        {
                            "type": "option",
                            "id": "1179"
                        },
                        {
                            "type": "option",
                            "id": "1181"
                        },
                        {
                            "type": "option",
                            "id": "1184"
                        },
                        {
                            "type": "option",
                            "id": "1185"
                        },
                        {
                            "type": "option",
                            "id": "1188"
                        }
                    ]
                }
            }
        },
        {
            "type": "profile",
            "id": "12606",
            "attributes": {
                "category": "bin_product_profile",
                "properties": [],
                "external_id": null
            },
            "relationships": {
                "options": {
                    "data": [
                        {
                            "type": "option",
                            "id": "993"
                        },
                        {
                            "type": "option",
                            "id": "1056"
                        },
                        {
                            "type": "option",
                            "id": "1108"
                        },
                        {
                            "type": "option",
                            "id": "1112"
                        },
                        {
                            "type": "option",
                            "id": "1156"
                        },
                        {
                            "type": "option",
                            "id": "1160"
                        },
                        {
                            "type": "option",
                            "id": "1169"
                        },
                        {
                            "type": "option",
                            "id": "1172"
                        },
                        {
                            "type": "option",
                            "id": "1173"
                        },
                        {
                            "type": "option",
                            "id": "1175"
                        },
                        {
                            "type": "option",
                            "id": "1177"
                        },
                        {
                            "type": "option",
                            "id": "1180"
                        },
                        {
                            "type": "option",
                            "id": "1182"
                        },
                        {
                            "type": "option",
                            "id": "1184"
                        },
                        {
                            "type": "option",
                            "id": "1185"
                        },
                        {
                            "type": "option",
                            "id": "1188"
                        }
                    ]
                }
            }
        },
        {
            "type": "profile",
            "id": "12607",
            "attributes": {
                "category": "bin_product_profile",
                "properties": [],
                "external_id": null
            },
            "relationships": {
                "options": {
                    "data": [
                        {
                            "type": "option",
                            "id": "993"
                        },
                        {
                            "type": "option",
                            "id": "1056"
                        },
                        {
                            "type": "option",
                            "id": "1108"
                        },
                        {
                            "type": "option",
                            "id": "1113"
                        },
                        {
                            "type": "option",
                            "id": "1156"
                        },
                        {
                            "type": "option",
                            "id": "1161"
                        },
                        {
                            "type": "option",
                            "id": "1169"
                        },
                        {
                            "type": "option",
                            "id": "1172"
                        },
                        {
                            "type": "option",
                            "id": "1173"
                        },
                        {
                            "type": "option",
                            "id": "1175"
                        },
                        {
                            "type": "option",
                            "id": "1177"
                        },
                        {
                            "type": "option",
                            "id": "1180"
                        },
                        {
                            "type": "option",
                            "id": "1182"
                        },
                        {
                            "type": "option",
                            "id": "1184"
                        },
                        {
                            "type": "option",
                            "id": "1185"
                        },
                        {
                            "type": "option",
                            "id": "1188"
                        }
                    ]
                }
            }
        }
    ],
    "included": [
        {
            "type": "option",
            "id": "1057",
            "attributes": {
                "category": "bin_product_profile_collection_type",
                "name": "Grue",
                "created_at": "2020-07-01T14:11:49.000000Z",
                "updated_at": "2020-07-01T14:11:49.000000Z"
            }
        },
        {
            "type": "option",
            "id": "1108",
            "attributes": {
                "category": "bin_product_profile_description",
                "name": "Contenant",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1110",
            "attributes": {
                "category": "bin_product_profile_container_type",
                "name": "CE \/ CSE",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1128",
            "attributes": {
                "category": "bin_product_profile_model",
                "name": "CSE 6,5 vc\/5000 L",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1157",
            "attributes": {
                "category": "bin_product_profile_fraction",
                "name": "Recyclage",
                "created_at": null,
                "updated_at": "2020-08-07T08:57:46.000000Z"
            }
        },
        {
            "type": "option",
            "id": "1166",
            "attributes": {
                "category": "bin_product_profile_volume",
                "name": "6,5 vc",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1169",
            "attributes": {
                "category": "bin_product_profile_lid",
                "name": "Oui",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1172",
            "attributes": {
                "category": "bin_product_profile_door",
                "name": "Non",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1174",
            "attributes": {
                "category": "bin_product_profile_wheel_rod",
                "name": "Non",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1175",
            "attributes": {
                "category": "bin_product_profile_lid_rod",
                "name": "Oui",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1177",
            "attributes": {
                "category": "bin_product_profile_tank",
                "name": "Oui",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1179",
            "attributes": {
                "category": "bin_product_profile_internal_tank",
                "name": "Oui",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1181",
            "attributes": {
                "category": "bin_product_profile_external_tank",
                "name": "Oui",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1184",
            "attributes": {
                "category": "bin_product_profile_handle",
                "name": "Non",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1185",
            "attributes": {
                "category": "bin_product_profile_muff",
                "name": "Oui",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1188",
            "attributes": {
                "category": "bin_product_profile_anchorage",
                "name": "Non",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1064",
            "attributes": {
                "category": "bin_product_profile_volume",
                "name": "4 vc",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1127",
            "attributes": {
                "category": "bin_product_profile_model",
                "name": "CSE 4 vc\/3000 L",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1066",
            "attributes": {
                "category": "bin_product_profile_volume",
                "name": "8 vc",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1129",
            "attributes": {
                "category": "bin_product_profile_model",
                "name": "CSE 8 vc\/6100 L",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "993",
            "attributes": {
                "category": "bin_product_profile_container_type",
                "name": "Bacs, sacs et poubelles",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1056",
            "attributes": {
                "category": "bin_product_profile_collection_type",
                "name": "ABS",
                "created_at": "2020-07-01T14:11:49.000000Z",
                "updated_at": "2020-07-01T14:11:49.000000Z"
            }
        },
        {
            "type": "option",
            "id": "1112",
            "attributes": {
                "category": "bin_product_profile_model",
                "name": "Bac roulant 240L",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1156",
            "attributes": {
                "category": "bin_product_profile_fraction",
                "name": "Déchets",
                "created_at": null,
                "updated_at": "2020-08-07T08:57:46.000000Z"
            }
        },
        {
            "type": "option",
            "id": "1160",
            "attributes": {
                "category": "bin_product_profile_volume",
                "name": "0,31 vc",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1173",
            "attributes": {
                "category": "bin_product_profile_wheel_rod",
                "name": "Oui",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1180",
            "attributes": {
                "category": "bin_product_profile_internal_tank",
                "name": "Non",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1182",
            "attributes": {
                "category": "bin_product_profile_external_tank",
                "name": "Non",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1113",
            "attributes": {
                "category": "bin_product_profile_model",
                "name": "Bac roulant 360L",
                "created_at": null,
                "updated_at": null
            }
        },
        {
            "type": "option",
            "id": "1161",
            "attributes": {
                "category": "bin_product_profile_volume",
                "name": "0,47 vc",
                "created_at": null,
                "updated_at": null
            }
        }
    ],
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 5,
            "total": 5,
            "last_page": 1
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v3\/profiles?filter%5Bcategory%5D=bin_product_profile&filter%5Bcustomer%5D=6&filter%5Bid%5D=12603%2C12604%2C12605%2C12606%2C12607&include=options&page=1",
        "first": "https:\/\/api.ci-web.eu\/api\/v3\/profiles?filter%5Bcategory%5D=bin_product_profile&filter%5Bcustomer%5D=6&filter%5Bid%5D=12603%2C12604%2C12605%2C12606%2C12607&include=options&page=1",
        "last": "https:\/\/api.ci-web.eu\/api\/v3\/profiles?filter%5Bcategory%5D=bin_product_profile&filter%5Bcustomer%5D=6&filter%5Bid%5D=12603%2C12604%2C12605%2C12606%2C12607&include=options&page=1"
    }
}

Example response (204):

[]

Example response (400):

{
    "errors": {
        "status": 400,
        "title": "Bad Request",
        "detail": ""
    }
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v3/profiles

Validator Customer requests

API Calls for managing the relation between a validator and a customer.

Class ValidatorCustomerController

GET Customer


Requires authentication Retrieve the customer for a given validator.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/validators/1/customer" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/validators/1/customer");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "customer",
        "id": 1,
        "attributes": {
            "created_at": "2014-02-07T09:58:44+00:00",
            "updated_at": "2014-09-16T15:29:33+00:00",
            "deleted_at": null,
            "name": "DEFAULT",
            "key_code": "default",
            "active": 1,
            "link_id": 1,
            "description": "gebruiken voor koppeling van acties",
            "category": "project_customer"
        },
        "relationships": {
            "geo-locations": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/1\/geo-locations"
                }
            },
            "modules": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/1\/modules"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/1"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/validators/{validator}/customer

Validator Options

All the endpoints for fetching and managing the options for a specific validator.

Class ValidatorOptionsController

GET Validator options

Endpoint returning all the options for a given validator.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/validators/1/options" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/validators/1/options");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 699,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "option",
            "id": 1,
            "attributes": {
                "created_at": "2012-09-25T17:48:14+00:00",
                "updated_at": "2019-07-19T11:06:24+00:00",
                "deleted_at": null,
                "link_id": null,
                "category": "other_garbage_event_origin",
                "name": "Burger"
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/options\/1"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/options",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/options?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v1\/options?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/options?page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/validators/{validator}/options

Validator Requests

API calls for managing Validators

Available Entity Types:

Name Description
product

GET Validators


Requires authentication Returns a list with Validators

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/validators? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/validators");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 3,
            "total": 3,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "validator",
            "id": 244,
            "attributes": {
                "created_at": "2020-02-24T10:40:39+00:00",
                "updated_at": "2020-02-24T10:40:39+00:00",
                "deleted_at": null,
                "entity_type": "product",
                "field": "chip_code",
                "validation_rules": [
                    "required"
                ],
                "priority": 0
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 524
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/244\/customers"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/244"
            }
        },
        {
            "type": "validator",
            "id": 245,
            "attributes": {
                "created_at": "2020-02-24T10:40:39+00:00",
                "updated_at": "2020-02-24T10:40:39+00:00",
                "deleted_at": null,
                "entity_type": "product",
                "field": "chip_code",
                "validation_rules": [
                    "required"
                ],
                "priority": 0
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 525
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/245\/customers"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/245"
            }
        },
        {
            "type": "validator",
            "id": 246,
            "attributes": {
                "created_at": "2020-02-24T10:40:39+00:00",
                "updated_at": "2020-02-24T10:40:39+00:00",
                "deleted_at": null,
                "entity_type": "product",
                "field": "chip_code",
                "validation_rules": [
                    "required"
                ],
                "priority": 0
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 526
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/246\/customers"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/246"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/validators",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/validators?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/validators?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/validators

Query Parameters

Parameter Status Description
filter[entity_type] optional Search on specific related entity_type.
filter[profile] optional Search on specific related profile.
filter[field] optional Search on specific field.

GET Single Validator


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/validators/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/validators/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "validator",
        "id": 374,
        "attributes": {
            "created_at": "2020-02-24T10:46:19+00:00",
            "updated_at": "2020-02-24T10:46:19+00:00",
            "deleted_at": null,
            "entity_type": "product",
            "field": "chip_code",
            "validation_rules": [
                "required"
            ],
            "priority": 0
        },
        "relationships": {
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 821
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/374\/customers"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/374"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/validators/{validator}

POST Validators


Requires authentication Creates a specific Validator

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/validators" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"validator","attributes":{"entity_type":"product","field":"cumque","validation_rules":"ut"},"relationships":{"profile":{"data":{"id":2,"type":"profile"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/validators");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "validator",
        "attributes": {
            "entity_type": "product",
            "field": "cumque",
            "validation_rules": "ut"
        },
        "relationships": {
            "profile": {
                "data": {
                    "id": 2,
                    "type": "profile"
                }
            }
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "validator",
        "id": 302,
        "attributes": {
            "created_at": "2020-02-24T10:42:34+00:00",
            "updated_at": "2020-02-24T10:42:34+00:00",
            "deleted_at": null,
            "entity_type": "product",
            "field": "chip_code",
            "validation_rules": [
                "required"
            ],
            "priority": 2
        },
        "relationships": {
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 650
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/302\/customers"
                }
            },
            "options": {
                "data": [
                    {
                        "type": "option",
                        "id": 1684
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/302\/options"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/302"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ]
    }
}

HTTP Request

POST api/v1/validators

Body Parameters

Parameter Type Status Description
data.type string optional required.
data.attributes.entity_type string. optional
data.attributes.field string optional required. Example chip_code
data.attributes.validation_rules json optional required. Example ["required"]
data.relationships.profile.data.id integer required id.
data.relationships.profile.data.type string optional required.

PATCH Validator


Requires authentication Updates a specific Validator

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/validators/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":1,"type":"validator","attributes":{"entity_type":"product","field":"qui","validation_rules":"inventore"},"relationships":{"profile":{"data":{"id":2,"type":"profile"}}}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/validators/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": 1,
        "type": "validator",
        "attributes": {
            "entity_type": "product",
            "field": "qui",
            "validation_rules": "inventore"
        },
        "relationships": {
            "profile": {
                "data": {
                    "id": 2,
                    "type": "profile"
                }
            }
        }
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "validator",
        "id": 329,
        "attributes": {
            "created_at": "2020-02-24T10:43:37+00:00",
            "updated_at": "2020-02-24T10:43:37+00:00",
            "deleted_at": null,
            "entity_type": "poi",
            "field": "bar_code",
            "validation_rules": [
                "hidden"
            ],
            "priority": 0
        },
        "relationships": {
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 719
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/329\/customers"
                }
            },
            "options": {
                "data": [
                    {
                        "type": "option",
                        "id": 1733
                    }
                ],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/329\/options"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/validator\/329"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type field is required."
        ]
    }
}

HTTP Request

PATCH api/v1/validators/{validator}

Body Parameters

Parameter Type Status Description
data.id integer optional required.
data.type string optional required.
data.attributes.entity_type string. optional
data.attributes.field string optional required. Example chip_code
data.attributes.validation_rules json optional required. Example ["required"]
data.relationships.profile.data.id integer required id.
data.relationships.profile.data.type string optional required.

DELETE a validator.

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v1/validators/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/validators/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

DELETE api/v1/validators/{validator}

general

GET Registrations


Requires authentication returns all registrations

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/registrations? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/registrations");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 10000,
            "last_page": 100
        },
        "warnings": []
    },
    "data": [
        {
            "type": "registration",
            "id": 3535,
            "attributes": {
                "created_at": "2019-12-26T10:59:38+00:00",
                "updated_at": "2019-12-26T10:59:38+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": 8745389,
                "category": "emptying_registration",
                "properties": {
                    "overruled": false
                },
                "line": "260",
                "chipcode": "00004849050816",
                "container_code": null,
                "vehicle_code": "01036",
                "fraction": null,
                "registration_started_at": "2016-01-06T09:12:40+00:00",
                "registration_ended_at": "2016-01-06T09:12:40+00:00",
                "unit": "kg",
                "gross_quantity": null,
                "terra_quantity": null,
                "net_quantity": 8,
                "validated_quantity": null,
                "latitude": 51.64582,
                "longitude": 4.866608,
                "external_id": null,
                "loader": "single",
                "memo": null,
                "status_codes": []
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 10304
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/10304"
                    }
                },
                "person": {
                    "data": {
                        "type": "person",
                        "id": 10288
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/10288"
                    }
                },
                "fraction_option": {
                    "data": {
                        "type": "option",
                        "id": 379
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/379"
                    }
                },
                "chip_product": {
                    "data": {
                        "type": "product",
                        "id": 10307
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/10307"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/3535"
            }
        },
        {
            "type": "registration",
            "id": 24220,
            "attributes": {
                "created_at": "2019-12-26T11:04:35+00:00",
                "updated_at": "2019-12-26T11:04:35+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": 8960448,
                "category": "emptying_registration",
                "properties": {
                    "overruled": false
                },
                "line": "190",
                "chipcode": "00004849050816",
                "container_code": null,
                "vehicle_code": "01035",
                "fraction": null,
                "registration_started_at": "2016-02-03T08:45:42+00:00",
                "registration_ended_at": "2016-02-03T08:45:42+00:00",
                "unit": "kg",
                "gross_quantity": null,
                "terra_quantity": null,
                "net_quantity": 11,
                "validated_quantity": null,
                "latitude": 51.64577,
                "longitude": 4.866482,
                "external_id": null,
                "loader": "right",
                "memo": null,
                "status_codes": []
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 10304
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/10304"
                    }
                },
                "person": {
                    "data": {
                        "type": "person",
                        "id": 10288
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/10288"
                    }
                },
                "fraction_option": {
                    "data": {
                        "type": "option",
                        "id": 379
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/379"
                    }
                },
                "chip_product": {
                    "data": {
                        "type": "product",
                        "id": 10307
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/10307"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/24220"
            }
        },
        {
            "type": "registration",
            "id": 10037,
            "attributes": {
                "created_at": "2019-12-26T11:01:36+00:00",
                "updated_at": "2019-12-26T11:01:36+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": 8809418,
                "category": "emptying_registration",
                "properties": {
                    "overruled": false
                },
                "line": "424",
                "chipcode": "00004849112517",
                "container_code": null,
                "vehicle_code": "01041",
                "fraction": null,
                "registration_started_at": "2016-01-13T12:52:11+00:00",
                "registration_ended_at": "2016-01-13T12:52:11+00:00",
                "unit": "kg",
                "gross_quantity": null,
                "terra_quantity": null,
                "net_quantity": 40,
                "validated_quantity": null,
                "latitude": 51.64577,
                "longitude": 4.86611,
                "external_id": null,
                "loader": "single",
                "memo": null,
                "status_codes": []
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 10305
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/10305"
                    }
                },
                "person": {
                    "data": {
                        "type": "person",
                        "id": 10289
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/10289"
                    }
                },
                "fraction_option": {
                    "data": {
                        "type": "option",
                        "id": 377
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/377"
                    }
                },
                "chip_product": {
                    "data": {
                        "type": "product",
                        "id": 10308
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/10308"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/10037"
            }
        },
        {
            "type": "registration",
            "id": 12439,
            "attributes": {
                "created_at": "2019-12-26T11:02:11+00:00",
                "updated_at": "2019-12-26T11:02:11+00:00",
                "deleted_at": null,
                "tags": [],
                "link_id": 8829395,
                "category": "emptying_registration",
                "properties": {
                    "overruled": false
                },
                "line": "38",
                "chipcode": "00004849102673",
                "container_code": null,
                "vehicle_code": "01041",
                "fraction": null,
                "registration_started_at": "2016-01-15T08:24:21+00:00",
                "registration_ended_at": "2016-01-15T08:24:21+00:00",
                "unit": "kg",
                "gross_quantity": null,
                "terra_quantity": null,
                "net_quantity": 35,
                "validated_quantity": null,
                "latitude": 51.59437,
                "longitude": 4.859902,
                "external_id": null,
                "loader": "single",
                "memo": null,
                "status_codes": []
            },
            "relationships": {
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/6"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 10305
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/10305"
                    }
                },
                "person": {
                    "data": {
                        "type": "person",
                        "id": 10289
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/10289"
                    }
                },
                "fraction_option": {
                    "data": {
                        "type": "option",
                        "id": 379
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/379"
                    }
                },
                "chip_product": {
                    "data": {
                        "type": "product",
                        "id": 32668
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/32668"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/12439"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/registrations",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/registrations?page%5Bnumber%5D=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/api\/v2\/registrations?page%5Bnumber%5D=2",
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/registrations?page%5Bnumber%5D=100"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/registrations

Query Parameters

Parameter Status Description
filter[collector] optional Find Registrations with given Collector id.

GET Registrations


Requires authentication returns single registrations

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/registrations/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/registrations/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "registration",
        "id": 37246,
        "attributes": {
            "created_at": "2019-01-01T12:13:33+00:00",
            "updated_at": "2019-01-05T13:14:44+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": 9102095,
            "category": "emptying_registration",
            "properties": [],
            "line": "5",
            "chipcode": "ABCDE12345",
            "container_code": "FGHIJK12345",
            "vehicle_code": "ABC-123",
            "fraction": "GFT",
            "registration_started_at": "2019-01-01T06:10:00+00:00",
            "registration_ended_at": "2019-01-01T06:11:00+00:00",
            "unit": "kg",
            "gross_quantity": 12.5,
            "terra_quantity": 2.4,
            "net_quantity": 10.1,
            "validated_quantity": 10,
            "latitude": 51.41,
            "longitude": 4.05,
            "external_id": "TEST-ID-1",
            "loader": "left",
            "memo": "This is a comment \/ memo field",
            "status_codes": [
                1,
                2,
                3
            ]
        },
        "relationships": {
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 10402
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/10402"
                }
            },
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 22864
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/22864"
                }
            },
            "person": {
                "data": {
                    "type": "person",
                    "id": 22323
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/22323"
                }
            },
            "event": {
                "data": {
                    "type": "event",
                    "id": 8112
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/8112"
                }
            },
            "registration_type": {
                "data": {
                    "type": "option",
                    "id": 8111
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/8111"
                }
            },
            "fraction_option": {
                "data": {
                    "type": "option",
                    "id": 8110
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/8110"
                }
            },
            "parent": {
                "data": {
                    "type": "registration",
                    "id": 37245
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v2\/registrations\/37245"
                }
            },
            "file": {
                "data": {
                    "type": "file",
                    "id": "A70DB4B4-B969-4488-9CA7-AEDC1D609D9A"
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/file\/v1\/files\/A70DB4B4-B969-4488-9CA7-AEDC1D609D9A"
                }
            },
            "chip_product": {
                "data": {
                    "type": "product",
                    "id": 52752
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/52752"
                }
            },
            "container_product": {
                "data": {
                    "type": "product",
                    "id": 52754
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/52754"
                }
            },
            "vehicle": {
                "data": {
                    "type": "vehicle",
                    "id": "5b9d4c29-c038-35ee-8b0e-7ff1580b5f14"
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/vehicles\/5b9d4c29-c038-35ee-8b0e-7ff1580b5f14"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/37246"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/registrations/{registration}

POST Registrations


Requires authentication Create new registrations

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v2/registrations" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/registrations");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (201):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "registration",
        "id": 37256,
        "attributes": {
            "created_at": "2020-05-26T08:50:57+00:00",
            "updated_at": "2020-05-26T08:50:57+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": null,
            "category": "emptying_registration",
            "properties": [],
            "line": "1",
            "chipcode": "CHIPCODE",
            "container_code": "CONTAINER_CODE",
            "vehicle_code": "TRUCK-123",
            "fraction": "GFT",
            "registration_started_at": "2019-01-01T06:00:00+00:00",
            "registration_ended_at": "2019-01-01T07:00:00+00:00",
            "unit": "kg",
            "gross_quantity": 10.4,
            "terra_quantity": 0.25,
            "net_quantity": 10.15,
            "validated_quantity": 10.1,
            "latitude": 51.41,
            "longitude": 4.5,
            "external_id": "TEST-ID-1",
            "loader": "right",
            "memo": "This is a comment",
            "status_codes": [
                123
            ]
        },
        "relationships": {
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 10455
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/10455"
                }
            },
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 22893
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/22893"
                }
            },
            "person": {
                "data": {
                    "type": "person",
                    "id": 22336
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/22336"
                }
            },
            "event": {
                "data": {
                    "type": "event",
                    "id": 9394
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/9394"
                }
            },
            "registration_type": {
                "data": {
                    "type": "option",
                    "id": 8120
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/8120"
                }
            },
            "fraction_option": {
                "data": {
                    "type": "option",
                    "id": 8121
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/8121"
                }
            },
            "parent": {
                "data": {
                    "type": "registration",
                    "id": 37255
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v2\/registrations\/37255"
                }
            },
            "file": {
                "data": {
                    "type": "file",
                    "id": "298FE87F-C250-4B16-8A31-DDC89C8D4319"
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/file\/v1\/files\/298FE87F-C250-4B16-8A31-DDC89C8D4319"
                }
            },
            "chip_product": {
                "data": {
                    "type": "product",
                    "id": 52770
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/52770"
                }
            },
            "container_product": {
                "data": {
                    "type": "product",
                    "id": 52771
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/52771"
                }
            },
            "vehicle": {
                "data": {
                    "type": "vehicle",
                    "id": "ed7eac58-a137-3108-a62a-544b470eddfa"
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/vehicles\/ed7eac58-a137-3108-a62a-544b470eddfa"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/37256"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

POST api/v2/registrations

PATCH Registrations


Requires authentication Update existing registrations

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v2/registrations/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/registrations/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "PATCH",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "registration",
        "id": 37266,
        "attributes": {
            "created_at": "2020-05-26T08:52:02+00:00",
            "updated_at": "2020-05-26T08:52:03+00:00",
            "deleted_at": null,
            "tags": [],
            "link_id": 9102110,
            "category": "emptying_registration",
            "properties": [],
            "line": "2",
            "chipcode": "CHIPCODE",
            "container_code": "CONTAINER_CODE",
            "vehicle_code": "TRUCK-456",
            "fraction": "REST",
            "registration_started_at": "2019-01-02T06:00:00+00:00",
            "registration_ended_at": "2019-01-02T07:00:00+00:00",
            "unit": "kg",
            "gross_quantity": 10.4,
            "terra_quantity": 0.25,
            "net_quantity": 10.15,
            "validated_quantity": 10.1,
            "latitude": 51.41,
            "longitude": 4.5,
            "external_id": "TEST-ID-2",
            "loader": "right",
            "memo": "This is a comment",
            "status_codes": [
                123
            ]
        },
        "relationships": {
            "customer": {
                "data": {
                    "type": "customer",
                    "id": 10517
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/customers\/10517"
                }
            },
            "poi": {
                "data": {
                    "type": "poi",
                    "id": 22927
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/22927"
                }
            },
            "person": {
                "data": {
                    "type": "person",
                    "id": 22352
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/22352"
                }
            },
            "event": {
                "data": {
                    "type": "event",
                    "id": 9397
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/events\/9397"
                }
            },
            "registration_type": {
                "data": {
                    "type": "option",
                    "id": 8129
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/8129"
                }
            },
            "fraction_option": {
                "data": {
                    "type": "option",
                    "id": 8130
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/options\/8130"
                }
            },
            "parent": {
                "data": {
                    "type": "registration",
                    "id": 37267
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v2\/registrations\/37267"
                }
            },
            "file": {
                "data": {
                    "type": "file",
                    "id": "298FE87F-C250-4B16-8A31-DDC89C8D4319"
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/file\/v1\/files\/298FE87F-C250-4B16-8A31-DDC89C8D4319"
                }
            },
            "chip_product": {
                "data": {
                    "type": "product",
                    "id": 52788
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/52788"
                }
            },
            "container_product": {
                "data": {
                    "type": "product",
                    "id": 52789
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/products\/52789"
                }
            },
            "vehicle": {
                "data": {
                    "type": "vehicle",
                    "id": "bf642eaf-6521-3777-8257-1d332e620324"
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/vehicles\/bf642eaf-6521-3777-8257-1d332e620324"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/registrations\/37266"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

PATCH api/v2/registrations/{registration}

DELETE Registration


Requires authentication Destroy registration

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/api/v2/registrations/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":2,"type":"registration"}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/registrations/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": 2,
        "type": "registration"
    }
}

fetch(url, {
    method: "DELETE",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (204):

[]

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The selected data.id is invalid."
        ],
        "data.type": [
            "The data.type value does not match required value."
        ]
    }
}

HTTP Request

DELETE api/v2/registrations/{registration}

Body Parameters

Parameter Type Status Description
data.id integer required ID of registration to delete.
data.type string required Type must be registration.

GET Registrations Summary

returns a summary of registrations (avg, total)


Requires authentication

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/registrations-summary? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/registrations-summary");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 1,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        }
    },
    "errors": null,
    "data": {
        "type": "average-registration",
        "id": null,
        "attributes": {
            "avg_registered_quantity": 17.95,
            "date_histogram_registered_quantity": {
                "2016": {
                    "total": 987,
                    "count": 55,
                    "statuses": {
                        "emptying_registration": 55
                    }
                }
            },
            "unit": "kg"
        }
    },
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/average-registrations",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/average-registrations?page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/average-registrations?page[number]=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v2/registrations-summary

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[category] optional Filter specific registration category.
filter[product] optional Find Registrations for given Product.
filter[registeredAt] optional Find Registrations for given RegisteredAt.
filter[registeredQuantity] optional Find Registrations for given RegisteredQuantity.
filter[validatedQuantity] optional Find Registrations for given ValidatedQuantity.
filter[registeredUnit] optional Find Registrations for given RegisteredUnit.
filter[chipcode] optional Find Registrations for given Chipcode.
filter[latitude] optional Find Registrations for given Latitude.
filter[longitude] optional Find Registrations for given Longitude.
filter[error] optional Find Registrations for given Error.
filter[person] optional Find Registrations for a given person.
filter[person_count] optional Find Registrations with .
filter[geo_location] optional Find Registrations for given geo Location.
filter[status_codes] optional Find Registrations for given status codes.

api/v1/elastic

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/api/v1/elastic" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/elastic");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST api/v1/elastic

PATCH Calendar properties


Requires authentication Updates the properties of a specific calendar.

Example request:

curl -X PATCH "https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/properties" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"id":1,"properties":"{\"key1\": \"value1\"}"}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/calendars/1/properties");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "id": 1,
        "properties": "{\"key1\": \"value1\"}"
    }
}

fetch(url, {
    method: "PATCH",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "calendar",
        "id": 1267,
        "attributes": {
            "created_at": "2019-10-29T15:47:50+00:00",
            "updated_at": "2019-10-29T15:47:50+00:00",
            "deleted_at": null,
            "tags": [],
            "category": "bin_product_calendar",
            "name": "laborum",
            "link_id": 1252,
            "from": "2018-10-30",
            "until": "2020-01-23",
            "dates": [],
            "properties": []
        },
        "relationships": {
            "profiles": {
                "data": [],
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1267\/profiles"
                }
            },
            "parent": {
                "data": {
                    "type": "calendar",
                    "id": null
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1267\/parents"
                }
            },
            "pois": {
                "link": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1267\/pois"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/calendars\/1267"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (405):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 405,
        "source": null,
        "title": "Method Not Allowed",
        "detail": "The GET method is not supported for this route."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.id": [
            "The data.id field is required.",
            "id mismatch, data.id value is not the same as in the link."
        ],
        "data.properties": [
            "The data.properties must be a valid JSON string."
        ]
    }
}

HTTP Request

PATCH api/v1/calendars/{calendar}/properties

Body Parameters

Parameter Type Status Description
data.id integer required The id must match the url id.
data.properties json optional optional Properties of this Calendar.

GET Index.

Endpoint to retrieve all the ExcludeProfileWhere entities.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/excluded-profiles" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/excluded-profiles");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 3,
            "total": 3,
            "last_page": 1
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "excluded-profile",
            "id": 69,
            "attributes": {
                "created_at": "2020-02-27T10:06:43+00:00",
                "updated_at": "2020-02-27T10:06:43+00:00",
                "deleted_at": null,
                "profile_id": 9341,
                "where_profile_id": 9342,
                "where_entity_type": "poi",
                "where_geo_location_id": 487
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/excluded-profiles\/69"
            }
        },
        {
            "type": "excluded-profile",
            "id": 70,
            "attributes": {
                "created_at": "2020-02-27T10:06:43+00:00",
                "updated_at": "2020-02-27T10:06:43+00:00",
                "deleted_at": null,
                "profile_id": 9341,
                "where_profile_id": 9343,
                "where_entity_type": "poi",
                "where_geo_location_id": 488
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/excluded-profiles\/70"
            }
        },
        {
            "type": "excluded-profile",
            "id": 71,
            "attributes": {
                "created_at": "2020-02-27T10:06:43+00:00",
                "updated_at": "2020-02-27T10:06:43+00:00",
                "deleted_at": null,
                "profile_id": 9341,
                "where_profile_id": 9344,
                "where_entity_type": "poi",
                "where_geo_location_id": 489
            },
            "relationships": [],
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/excluded-profiles\/71"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/9341\/excluded-profiles",
        "first": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/9341\/excluded-profiles?page%5Bnumber%5D=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v2\/profiles\/9341\/excluded-profiles?page%5Bnumber%5D=1"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/excluded-profiles

GET Show

Endpoint to fetch a single ExcludeProfilesWhere entity.

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/excluded-profiles/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/excluded-profiles/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "excluded-profile",
        "id": 123,
        "attributes": {
            "created_at": "2020-02-27T10:59:50+00:00",
            "updated_at": "2020-02-27T10:59:50+00:00",
            "deleted_at": null,
            "profile_id": 9644,
            "where_profile_id": 9645,
            "where_entity_type": "poi",
            "where_geo_location_id": 764
        },
        "relationships": [],
        "links": {
            "self": "https:\/\/api.ci-web.eu\/api\/v1\/excluded-profiles\/123"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET api/v1/excluded-profiles/{excludeProfilesWhere}

api/v1/persons

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/persons" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/persons");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/persons

api/v1/pois

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/pois

api/v1/pois/{poi}

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/pois/{poi}

api/v1/pois/{poi}/products

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/products" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/pois/1/products");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/pois/{poi}/products

api/v1/products

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/products" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/products");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/products

api/v1/products/{product}

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/products/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/products/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/products/{product}

GET Related pois


Requires authentication Returns the related Pois for a given ProductRelatedPois

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/products/1/related-pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/products/1/related-pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 1,
            "total": 1,
            "last_page": 1
        }
    },
    "errors": null,
    "data": [
        {
            "type": "poi",
            "id": 27205,
            "attributes": {
                "created_at": "2019-10-18T12:15:43+00:00",
                "updated_at": "2019-10-18T12:15:43+00:00",
                "deleted_at": null,
                "tags": [],
                "street": "Verenigd Koninkrijk",
                "city": "Verenigd Koninkrijk",
                "country": "Verenigd Koninkrijk",
                "category": "collect_poi",
                "number": null,
                "letter": null,
                "addition": null,
                "zipcode": "",
                "position": null,
                "person_count": 0
            },
            "relationships": {
                "street": {
                    "data": {
                        "type": "geo_location",
                        "id": 83292
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/27205\/streets"
                    }
                },
                "city": {
                    "data": {
                        "type": "geo_location",
                        "id": 83291
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/27205\/cities"
                    }
                },
                "country": {
                    "data": {
                        "type": "geo_location",
                        "id": 83290
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/27205\/countries"
                    }
                },
                "events": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/27205\/events"
                    }
                },
                "products": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/27205\/products"
                    }
                },
                "profiles": {
                    "data": [],
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/27205\/profiles"
                    }
                },
                "customer": {
                    "data": {
                        "type": "customer",
                        "id": null
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/27205\/customer"
                    }
                },
                "related-pois": {
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/27205\/related-pois?filter[category]=ciaccess_poi,collect_poi,collective_poi,deliver_poi,event_poi,invoice_poi,residential_poi,send_invoice_to_poi"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/27205"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/api\/v1\/products\/2194\/related-pois?filter[category]=collect_poi&filters[category]=collect_poi",
        "first": "https:\/\/api.ci-web.eu\/api\/v1\/products\/2194\/related-pois?filter[category]=collect_poi&filters[category]=collect_poi&page[number]=1",
        "prev": null,
        "next": null,
        "last": "https:\/\/api.ci-web.eu\/api\/v1\/products\/2194\/related-pois?filter[category]=collect_poi&filters[category]=collect_poi&page[number]=1"
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "filter.category": [
            "The filter.category field is required.",
            "The selected filter.category is invalid."
        ]
    }
}

HTTP Request

GET api/v1/products/{product}/related-pois

api/v1/registrations

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/registrations" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/registrations");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/registrations

api/v1/average-registrations

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/average-registrations" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/average-registrations");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/average-registrations

api/v1/search

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v1/search" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v1/search");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v1/search

api/v2/geo-locations

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/geo-locations" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/geo-locations");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v2/geo-locations

api/v2/geo-locations/{geoLocation}

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/geo-locations/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/geo-locations/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v2/geo-locations/{geoLocation}

api/v2/events

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/events" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/events");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v2/events

api/v2/events/{event}

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v2/events/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v2/events/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v2/events/{event}

api/v3/registrations

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v3/registrations" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v3/registrations");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v3/registrations

api/v3/registrations/{registration}

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/api/v3/registrations/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/api/v3/registrations/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET api/v3/registrations/{registration}

custom/v1/messages

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/messages" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/messages");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/messages

POST person login credentials


Requires authentication

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/the-studio/auth/login" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}" \
    -d '{"data":{"type":"login","attributes":{"identification_number":"12345667890","password":"$2y$12$bgz1JGhLwwOdWceob4ipBuufkG1lbfdcf4Q7xqH4nsOHSO4Hw.wWO"}}}'
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/the-studio/auth/login");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

let body = {
    "data": {
        "type": "login",
        "attributes": {
            "identification_number": "12345667890",
            "password": "$2y$12$bgz1JGhLwwOdWceob4ipBuufkG1lbfdcf4Q7xqH4nsOHSO4Hw.wWO"
        }
    }
}

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

null

Example response (422):

{
    "message": "The given data was invalid.",
    "errors": {
        "data.type": [
            "The data.type value does not match required value."
        ],
        "data.attributes.identification_number": [
            "The data.attributes.identification_number field is required."
        ],
        "data.attributes.password": [
            "The data.attributes.password field is required."
        ]
    }
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

Example response (401):

null

HTTP Request

POST custom/v1/the-studio/auth/login

Body Parameters

Parameter Type Status Description
data.type string required Type must be login.
data.attributes.identification_number string/integer required identification_number of the person to verify.
data.attributes.password bcrypt optional string Password must be a bcrypt string.

GET invoices


Requires authentication Returns all invoices

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/the-studio/pom-invoices? " \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/the-studio/pom-invoices");

    let params = {
                };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": {
            "current_page": 1,
            "per_page": 100,
            "from": 1,
            "to": 100,
            "total": 619,
            "last_page": 7
        },
        "warnings": []
    },
    "errors": null,
    "data": [
        {
            "type": "pom-invoice",
            "id": 5,
            "attributes": {
                "created_at": "2016-03-09T13:43:04+00:00",
                "updated_at": "2017-06-29T13:30:01+00:00",
                "deleted_at": null,
                "paylink": "https:\/\/beta-senders.api.letspom.eu\/paylink?senderContractNumber=ADD000439&iv=some-long-hash=&channel=APP",
                "ogm": "000000000097",
                "payed_status": "PAYED",
                "payed_at": "2019-11-26",
                "amount": "250.00",
                "currency": "EUR",
                "due_date": "2020-02-01",
                "invoice_number": "201601015698"
            },
            "relationships": {
                "persons": {
                    "data": {
                        "type": "person",
                        "id": 4
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/4"
                    }
                },
                "poi": {
                    "data": {
                        "type": "poi",
                        "id": 6
                    },
                    "links": {
                        "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/6"
                    }
                }
            },
            "links": {
                "self": "https:\/\/api.ci-web.eu\/custom\/v1\/the-studio\/pom-invoices\/5"
            }
        }
    ],
    "links": {
        "self": "https:\/\/api.ci-web.eu\/custom\/v1\/the-studio\/pom-invoices",
        "first": "https:\/\/api.ci-web.eu\/custom\/v1\/the-studio\/pom-invoices?page[number]=1",
        "prev": null,
        "next": "https:\/\/api.ci-web.eu\/custom\/v1\/the-studio\/pom-invoices?page[number]=2",
        "last": "https:\/\/api.ci-web.eu\/custom\/v1\/the-studio\/pom-invoices?page[number]=7"
    }
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET custom/v1/the-studio/pom-invoices

Query Parameters

Parameter Status Description
filter[id] optional Search for specific id or ids.
filter[person] optional Filter specific Person.

GET invoice


Requires authentication returns a specific invoice

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/the-studio/pom-invoices/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/the-studio/pom-invoices/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": null,
    "data": {
        "type": "pom-invoice",
        "id": 5,
        "attributes": {
            "created_at": "2016-03-09T13:43:04+00:00",
            "updated_at": "2017-06-29T13:30:01+00:00",
            "deleted_at": null,
            "paylink": "https:\/\/beta-senders.api.letspom.eu\/paylink?senderContractNumber=ADD000439&iv=some-long-hash=&channel=APP",
            "ogm": "000000000097",
            "payed_status": "CLOSED",
            "payed_at": "2019-11-26",
            "amount": "250.00",
            "currency": "EUR",
            "due_date": "2020-02-01",
            "invoice_number": "201601015698"
        },
        "relationships": {
            "person": {
                "data": {
                    "id": 4,
                    "type": "person"
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/persons\/4"
                }
            },
            "poi": {
                "data": {
                    "id": 6,
                    "type": "poi"
                },
                "links": {
                    "related": "https:\/\/api.ci-web.eu\/api\/v1\/pois\/6"
                }
            }
        },
        "links": {
            "self": "https:\/\/api.ci-web.eu\/custom\/v1\/the-studio\/pom-invoices\/pom-invoices\/5"
        }
    },
    "links": []
}

Example response (401):

{
    "message": "Unauthenticated."
}

Example response (403):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 403,
        "source": null,
        "title": "Forbidden",
        "detail": "This action is unauthorized."
    },
    "data": null,
    "links": null
}

Example response (404):

{
    "meta": {
        "page": null,
        "warnings": []
    },
    "errors": {
        "code": 404,
        "source": null,
        "title": "Not Found",
        "detail": "Requested resource was not found in our database."
    },
    "data": null,
    "links": null
}

HTTP Request

GET custom/v1/the-studio/pom-invoices/{invoiceId}

Custom call handle registration requests

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/amcs/bulk/import/registrations" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/amcs/bulk/import/registrations");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/amcs/bulk/import/registrations

custom/v1/app-site/persons/verify

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/app-site/persons/verify" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/app-site/persons/verify");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/app-site/persons/verify

custom/v1/app-site/finance-overview/{person}

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/app-site/finance-overview/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/app-site/finance-overview/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/app-site/finance-overview/{person}

custom/v1/app-site/cluster-finance-overview/{poi}

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/app-site/cluster-finance-overview/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/app-site/cluster-finance-overview/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/app-site/cluster-finance-overview/{poi}

custom/v1/app-finance/icontroller/people

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/app-finance/icontroller/people" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/app-finance/icontroller/people");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/app-finance/icontroller/people

custom/v1/app-monitor/reports/{module}/{report}

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/app-monitor/reports/1/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/app-monitor/reports/1/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/app-monitor/reports/{module}/{report}

custom/v1/opzet/poi-bin-calendar

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/opzet/poi-bin-calendar" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/opzet/poi-bin-calendar");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/opzet/poi-bin-calendar

custom/v1/opzet/etten-leur-diftar

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/opzet/etten-leur-diftar" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/opzet/etten-leur-diftar");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/opzet/etten-leur-diftar

custom/v1/opzet/poi-history-other-garbage-events

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/opzet/poi-history-other-garbage-events" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/opzet/poi-history-other-garbage-events");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/opzet/poi-history-other-garbage-events

custom/v1/ci-fact/provisions

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/ci-fact/provisions" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/ci-fact/provisions");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/ci-fact/provisions

custom/v1/stosag/transactions-system-information/{project}

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/stosag/transactions-system-information/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/stosag/transactions-system-information/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/stosag/transactions-system-information/{project}

custom/v1/irc/card/setWithLinkThroughCardContainerGroup

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/irc/card/setWithLinkThroughCardContainerGroup" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/irc/card/setWithLinkThroughCardContainerGroup");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/irc/card/setWithLinkThroughCardContainerGroup

custom/v1/irc/card/block

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/irc/card/block" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/irc/card/block");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/irc/card/block

custom/v1/irc/card/unblock

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/irc/card/unblock" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/irc/card/unblock");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/irc/card/unblock

custom/v1/irc/card/batchBalanceUpdate

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/irc/card/batchBalanceUpdate" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/irc/card/batchBalanceUpdate");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/irc/card/batchBalanceUpdate

custom/v1/cluster/{poi}/linked-pois

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-pois" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-pois");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/cluster/{poi}/linked-pois

custom/v1/cluster/{poi}/linked-actions

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-actions" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-actions");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/cluster/{poi}/linked-actions

custom/v1/cluster/{poi}/linked-ciaccess-dumpings

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-ciaccess-dumpings" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-ciaccess-dumpings");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/cluster/{poi}/linked-ciaccess-dumpings

custom/v1/cluster/{poi}/linked-emptyings

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-emptyings" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-emptyings");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/cluster/{poi}/linked-emptyings

custom/v1/cluster/{poi}/linked-other-garbages

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-other-garbages" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-other-garbages");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/cluster/{poi}/linked-other-garbages

custom/v1/cluster/{poi}/linked-payments

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-payments" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-payments");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/cluster/{poi}/linked-payments

custom/v1/cluster/{poi}/linked-rc-dumpings

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-rc-dumpings" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/cluster/1/linked-rc-dumpings");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/cluster/{poi}/linked-rc-dumpings

custom/v2/wastedrop/find-person

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v2/wastedrop/find-person" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v2/wastedrop/find-person");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v2/wastedrop/find-person

custom/v2/wastedrop/projects

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v2/wastedrop/projects" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v2/wastedrop/projects");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v2/wastedrop/projects

custom/v1/wastedrop/find-person

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/find-person" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/find-person");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/find-person

custom/v1/wastedrop/projects

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/projects" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/projects");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/wastedrop/projects

custom/v1/wss/CheckCard

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wss/CheckCard" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wss/CheckCard");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wss/CheckCard

custom/v1/event/ciaccess-complaint-event/{project}

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/event/ciaccess-complaint-event/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/event/ciaccess-complaint-event/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/event/ciaccess-complaint-event/{project}

custom/v1/wastedrop/persons

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/persons" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/persons");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/wastedrop/persons

custom/v1/wastedrop/transactions

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/transactions" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/transactions");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/transactions

custom/v1/wastedrop/transactions/{transactionId}/capture

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/transactions/1/capture" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/transactions/1/capture");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/transactions/{transactionId}/capture

custom/v1/wastedrop/diftar-accounts

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/wastedrop/diftar-accounts

custom/v1/wastedrop/diftar-accounts

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/diftar-accounts

custom/v1/wastedrop/diftar-accounts/{accountId}

Example request:

curl -X DELETE "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "DELETE",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

DELETE custom/v1/wastedrop/diftar-accounts/{accountId}

custom/v1/wastedrop/diftar-accounts/{accountId}/balance

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1/balance" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1/balance");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/wastedrop/diftar-accounts/{accountId}/balance

custom/v1/wastedrop/diftar-accounts/{accountId}/transactions

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1/transactions" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1/transactions");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/diftar-accounts/{accountId}/transactions

custom/v1/wastedrop/diftar-accounts/{accountId}/top-ups

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1/top-ups" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1/top-ups");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/diftar-accounts/{accountId}/top-ups

custom/v1/wastedrop/diftar-accounts/{accountId}/transactions/{transactionId}/capture

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1/transactions/1/capture" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1/transactions/1/capture");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/diftar-accounts/{accountId}/transactions/{transactionId}/capture

custom/v1/wastedrop/containers

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/containers" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/containers");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/wastedrop/containers

custom/v1/wastedrop/containers/{containerId}

Example request:

curl -X GET -G "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/containers/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/containers/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

GET custom/v1/wastedrop/containers/{containerId}

custom/v1/wastedrop/containers/{containerId}/transactions

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/containers/1/transactions" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/containers/1/transactions");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/containers/{containerId}/transactions

custom/v1/wastedrop/containers/{containerId}/transactions/{transactionId}

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/containers/1/transactions/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/containers/1/transactions/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/containers/{containerId}/transactions/{transactionId}

custom/v1/wastedrop/transactions/{transactionId}/status

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/transactions/1/status" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/transactions/1/status");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/transactions/{transactionId}/status

custom/v1/wastedrop/diftar-accounts/{accountId}/top-ups/{topUpId}

Example request:

curl -X POST "https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1/top-ups/1" \
    -H "Content-Type: application/json" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://api.eu-acc-006.ci-web.eu/custom/v1/wastedrop/diftar-accounts/1/top-ups/1");

let headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
    "Authorization": "Bearer {token}",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

POST custom/v1/wastedrop/diftar-accounts/{accountId}/top-ups/{topUpId}