Glue API: Retrieve services

Edit on GitHub

This endpoint lets you retrieve services.

Installation

Install the Service Points feature

Retrieve services


GET /services


Request

HEADER KEY HEADER VALUE REQUIRED DESCRIPTION
Authorization string Alphanumeric string that authorizes the warehouse user to send requests to protected resources. Get it by authenticating as a warehouse user.
QUERY PARAMETER DESCRIPTION POSSIBLE VALUES
include Adds resource relationships to the request. service-points service-types
REQUEST USAGE
GET https://glue-backend.mysprykershop.com/services Retrieve all services.
GET https://glue-backend.mysprykershop.com/services?include=service-types Retrieve services with service types included.
GET https://glue-backend.mysprykershop.com/services?include=service-points Retrieve services with service points included.

Response

Retrieve services
{
    "data": [
        {
            "type": "services",
            "id": "37ef89d3-7792-533c-951c-981c6b56312c",
            "attributes": {
                "uuid": "37ef89d3-7792-533c-951c-981c6b56312c",
                "isActive": true,
                "key": "s1"
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/services/37ef89d3-7792-533c-951c-981c6b56312c"
            }
        },
        {
            "type": "services",
            "id": "6358f60b-958b-53f9-9401-306c063b1282",
            "attributes": {
                "uuid": "6358f60b-958b-53f9-9401-306c063b1282",
                "isActive": true,
                "key": "s2"
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/services/6358f60b-958b-53f9-9401-306c063b1282"
            }
        }
    ],
    "links": {
        "self": "https://glue-backend.mysprykershop.com/services"
    }
}
Retrieve services with service types included
{
    "data": [
        {
            "type": "services",
            "id": "37ef89d3-7792-533c-951c-981c6b56312c",
            "attributes": {
                "uuid": "37ef89d3-7792-533c-951c-981c6b56312c",
                "isActive": true,
                "key": "s1"
            },
            "relationships": {
                "service-types": {
                    "data": [
                        {
                            "type": "service-types",
                            "id": "2370ad95-4e9f-5ac3-913e-300c5805b181"
                        }
                    ]
                }
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/services/37ef89d3-7792-533c-951c-981c6b56312c?include=service-types"
            }
        },
        {
            "type": "services",
            "id": "6358f60b-958b-53f9-9401-306c063b1282",
            "attributes": {
                "uuid": "6358f60b-958b-53f9-9401-306c063b1282",
                "isActive": true,
                "key": "s2"
            },
            "relationships": {
                "service-types": {
                    "data": [
                        {
                            "type": "service-types",
                            "id": "2370ad95-4e9f-5ac3-913e-300c5805b181"
                        }
                    ]
                }
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/services/6358f60b-958b-53f9-9401-306c063b1282?include=service-types"
            }
        }
    ],
    "links": {
        "self": "https://glue-backend.mysprykershop.com/services?include=service-types"
    },
    "included": [
        {
            "type": "service-types",
            "id": "2370ad95-4e9f-5ac3-913e-300c5805b181",
            "attributes": {
                "name": "Pickup",
                "key": "pickup"
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/service-types/2370ad95-4e9f-5ac3-913e-300c5805b181?include=service-types"
            }
        }
    ]
}
Retrieve services with service points included
{
    "data": [
        {
            "type": "services",
            "id": "37ef89d3-7792-533c-951c-981c6b56312c",
            "attributes": {
                "uuid": "37ef89d3-7792-533c-951c-981c6b56312c",
                "isActive": true,
                "key": "s1"
            },
            "relationships": {
                "service-points": {
                    "data": [
                        {
                            "type": "service-points",
                            "id": "262feb9d-33a7-5c55-9b04-45b1fd22067e"
                        }
                    ]
                }
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/services/37ef89d3-7792-533c-951c-981c6b56312c?include=service-points"
            }
        },
        {
            "type": "services",
            "id": "6358f60b-958b-53f9-9401-306c063b1282",
            "attributes": {
                "uuid": "6358f60b-958b-53f9-9401-306c063b1282",
                "isActive": true,
                "key": "s2"
            },
            "relationships": {
                "service-points": {
                    "data": [
                        {
                            "type": "service-points",
                            "id": "7e3b03e0-c53c-5298-9ece-968f4628b4f8"
                        }
                    ]
                }
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/services/6358f60b-958b-53f9-9401-306c063b1282?include=service-points"
            }
        }
    ],
    "links": {
        "self": "https://glue-backend.mysprykershop.com/services?include=service-points"
    },
    "included": [
        {
            "type": "service-points",
            "id": "262feb9d-33a7-5c55-9b04-45b1fd22067e",
            "attributes": {
                "name": "Spryker Main Store",
                "key": "sp1",
                "isActive": true,
                "stores": [
                    "DE",
                    "AT"
                ]
            },
            "relationships": {
                "services": {
                    "data": [
                        {
                            "type": "services",
                            "id": "37ef89d3-7792-533c-951c-981c6b56312c"
                        }
                    ]
                }
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/service-points/262feb9d-33a7-5c55-9b04-45b1fd22067e?include=service-points"
            }
        },
        {
            "type": "service-points",
            "id": "7e3b03e0-c53c-5298-9ece-968f4628b4f8",
            "attributes": {
                "name": "Spryker Berlin Store",
                "key": "sp2",
                "isActive": true,
                "stores": [
                    "DE",
                    "AT"
                ]
            },
            "relationships": {
                "services": {
                    "data": [
                        {
                            "type": "services",
                            "id": "6358f60b-958b-53f9-9401-306c063b1282"
                        }
                    ]
                }
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/service-points/7e3b03e0-c53c-5298-9ece-968f4628b4f8?include=service-points"
            }
        }
    ]
}
RESOURCE ATTRIBUTE TYPE DESCRIPTION
services uuid String Unique identifier of the service.
services isActive Boolean Defines if the service is active. Inactive services are not displayed on the Storefront.
services key String Unique key of the service. It’s used as a reference when assigning services to service points.
RESOURCE ATTRIBUTE TYPE DESCRIPTION
service-points name String This name is displayed on the Storefront.
service-points key String Unique identifier of the service point.
service-points isActive Boolean Defines if the service point is active. If it’s inactive, customers can’t select it.
service-points stores Object Defines the stores the service point is available in.
RESOURCE ATTRIBUTE TYPE DESCRIPTION
service-types name String Name.
service-types key String Unique key of the service type. You will use it as a reference when adding services of this type.

Retrieve a service


GET /services/{{service_id}}


PATH PARAMETER DESCRIPTION
{{service_id}} ID of a service to retrieve. To get it, add a service or retrieve services.

Request

HEADER KEY HEADER VALUE REQUIRED DESCRIPTION
Authorization string Alphanumeric string that authorizes the warehouse user to send requests to protected resources. Get it by authenticating as a warehouse user.
QUERY PARAMETER DESCRIPTION EXEMPLARY VALUES
include Adds resource relationships to the request. service-types service-points
REQUEST USAGE
GET https://glue-backend.mysprykershop.com/services/37ef89d3-7792-533c-951c-981c6b56312c Retrieve a service with the specified ID.
GET https://glue-backend.mysprykershop.com/services/37ef89d3-7792-533c-951c-981c6b56312c?include=service-types Retrieve a service point with the specified ID. Include the information about its services.
GET https://glue-backend.mysprykershop.com/services/37ef89d3-7792-533c-951c-981c6b56312c?include=service-types Retrieve a service point with the specified ID. Include the information about its address.

Response

Retrieve a service with the specified ID
{
    "data": {
        "type": "services",
        "id": "37ef89d3-7792-533c-951c-981c6b56312c",
        "attributes": {
            "uuid": "37ef89d3-7792-533c-951c-981c6b56312c",
            "isActive": true,
            "key": "s1"
        },
        "links": {
            "self": "https://glue-backend.mysprykershop.com/services/37ef89d3-7792-533c-951c-981c6b56312c"
        }
    }
}
Retrieve a service with the specified ID. Include information about its service type
{
    "data": {
        "type": "services",
        "id": "37ef89d3-7792-533c-951c-981c6b56312c",
        "attributes": {
            "uuid": "37ef89d3-7792-533c-951c-981c6b56312c",
            "isActive": true,
            "key": "s1"
        },
        "relationships": {
            "service-types": {
                "data": [
                    {
                        "type": "service-types",
                        "id": "2370ad95-4e9f-5ac3-913e-300c5805b181"
                    }
                ]
            }
        },
        "links": {
            "self": "https://glue-backend.mysprykershop.com/services/37ef89d3-7792-533c-951c-981c6b56312c?include=service-types"
        }
    },
    "included": [
        {
            "type": "service-types",
            "id": "2370ad95-4e9f-5ac3-913e-300c5805b181",
            "attributes": {
                "name": "Pickup",
                "key": "pickup"
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/service-types/2370ad95-4e9f-5ac3-913e-300c5805b181?include=service-types"
            }
        }
    ]
}
Retrieve a service point with the specified ID. Include information about its service point
{
    "data": {
        "type": "services",
        "id": "37ef89d3-7792-533c-951c-981c6b56312c",
        "attributes": {
            "uuid": "37ef89d3-7792-533c-951c-981c6b56312c",
            "isActive": true,
            "key": "s1"
        },
        "relationships": {
            "service-points": {
                "data": [
                    {
                        "type": "service-points",
                        "id": "262feb9d-33a7-5c55-9b04-45b1fd22067e"
                    }
                ]
            }
        },
        "links": {
            "self": "https://glue-backend.mysprykershop.com/services/37ef89d3-7792-533c-951c-981c6b56312c?include=service-points"
        }
    },
    "included": [
        {
            "type": "service-points",
            "id": "262feb9d-33a7-5c55-9b04-45b1fd22067e",
            "attributes": {
                "name": "Spryker Main Store",
                "key": "sp1",
                "isActive": true,
                "stores": [
                    "DE",
                    "AT"
                ]
            },
            "links": {
                "self": "https://glue-backend.mysprykershop.com/service-points/262feb9d-33a7-5c55-9b04-45b1fd22067e?include=service-points"
            }
        }
    ]
}
RESOURCE ATTRIBUTE TYPE DESCRIPTION
services uuid String Unique identifier of the service.
services isActive Boolean Defines if the service is active. Inactive services are not displayed on the Storefront.
services key String Unique key of the service. It’s used as a reference when assigning services to service points.
RESOURCE ATTRIBUTE TYPE DESCRIPTION
service-points name String This name is displayed on the Storefront.
service-points key String Unique identifier of the service point.
service-points isActive Boolean Defines if the service point is active. If it’s inactive, customers can’t select it.
service-points stores Object Defines the stores the service point is available in.
RESOURCE ATTRIBUTE TYPE DESCRIPTION
service-types name String Name.
service-types key String Unique key of the service type. You will use it as a reference when adding services of this type.

Possible errors

CODE REASON
5403 The service point with the specified ID doesn’t exist.

To view generic errors that originate from the Glue Application, see Reference information: GlueApplication errors.