---
updatedAt: 2025-05-21T09:37:30.000Z
agentTools:
  projectIndex: https://toursolver.readme.io/llms.txt
---

# Get known depots

Get depots defined in ToursolverCloud GUI

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "servers": [
    {
      "url": "https://api.geoconcept.com/tsapi",
      "description": "Production",
      "variables": {}
    }
  ],
  "info": {
    "contact": {
      "email": "support@nomadia-group.com",
      "name": "Nomadia Group",
      "url": "https://www.nomadia-group.com/contact/"
    },
    "description": "Web APIs for TourSolver.",
    "title": "TourSolver API",
    "version": "2.0"
  },
  "tags": [
    {
      "description": "Start optimizations, follow the progress, retrieve the results, etc",
      "name": "Optimization"
    }
  ],
  "paths": {
    "/depots": {
      "get": {
        "description": "Get depots defined in ToursolverCloud GUI",
        "operationId": "getDepots",
        "parameters": [
          {
            "description": "if a depot name is specified only one depot will be returned",
            "in": "query",
            "name": "depotName",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "default": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DepotsResult"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/DepotsResult"
                }
              },
              "text/xml": {
                "schema": {
                  "$ref": "#/components/schemas/DepotsResult"
                }
              }
            },
            "description": "DepotsResult with a list of depots"
          }
        },
        "security": [
          {
            "apiKey": []
          }
        ],
        "servers": [
          {
            "description": "Production",
            "url": "https://api.geoconcept.com/tsapi",
            "variables": {}
          }
        ],
        "summary": "Get known depots",
        "tags": [
          "Optimization"
        ]
      }
    }
  },
  "components": {
    "schemas": {
      "DepotsResult": {
        "type": "object",
        "properties": {
          "depots": {
            "type": "array",
            "description": "List of depots",
            "items": {
              "$ref": "#/components/schemas/TSDepot"
            }
          },
          "errCode": {
            "type": "string",
            "description": "Error code",
            "enum": [
              "0",
              "1",
              "2",
              "3",
              "4",
              "5",
              "6",
              "7",
              "8",
              "9",
              "10",
              "11",
              "12",
              "13",
              "14",
              "100",
              "101",
              "102",
              "103",
              "104",
              "105",
              "106",
              "107",
              "108",
              "109",
              "110",
              "111",
              "112",
              "113",
              "114",
              "115",
              "116",
              "200",
              "201",
              "300",
              "301",
              "400",
              "401",
              "500",
              "501",
              "502",
              "600",
              "601",
              "602",
              "603",
              "604",
              "1000",
              "1001",
              "1002",
              "1003",
              "1004",
              "1006",
              "1007",
              "1008",
              "2000",
              "2001",
              "2002",
              "2003",
              "2004",
              "2005",
              "2006",
              "2007",
              "2008",
              "2009",
              "2010",
              "2011",
              "2021",
              "2022",
              "2023",
              "2024",
              "2025",
              "2026",
              "2027",
              "2028",
              "2029",
              "2030",
              "2031",
              "3000",
              "3001",
              "3002",
              "4000",
              "4001",
              "4002",
              "5000",
              "5001",
              "5002",
              "5003",
              "6000"
            ]
          },
          "message": {
            "type": "string",
            "description": "Error message"
          },
          "status": {
            "type": "string",
            "description": "OK or ERROR",
            "enum": [
              "OK",
              "ERROR"
            ]
          }
        }
      },
      "TSDepot": {
        "type": "object",
        "description": "The Depots object stores depots data. They are composed of X, Y coordinates,\nidentity tags, and a set of constraints.\n\nIf you want to specify depot locations or allow a resource to reload at\nseveral depots, use the Depots object to add and configure your depot data.\nThe Depots object contains zero or more elements. If it contains no elements,\nthe base location of each resource acts as a depot location. Once a depot is\nassociated with a resource, its base location is no longer used as a depot\nlocation.",
        "properties": {
          "allProductsRequired": {
            "type": "boolean",
            "description": "Indicates whether a resource must provide all required products or at least one.\nSet it to True to indicate that a resource must provide all the depot required products.\nSet it to False to indicate that a resource must provide at least one of the depot required products.\n\n**Type:** boolean\n\n**Default:** True"
          },
          "availability": {
            "type": "boolean",
            "description": "Indicates whether a depot is included in the planning process or not.\n\nThis constraint enables you to easily modify your optimization problem configuration without having to add nor delete your original data.\n\n* Set it to True to include a depot element in the planning process.\n\n* Set it to False to ignore it: it will not be used in the planning."
          },
          "deliveryQuantities": {
            "type": "array",
            "description": "The available quantities of products at the depot.\nYou can specify up to 24 quantities.\n\n**Type:** float array",
            "items": {
              "type": "integer",
              "format": "int32"
            },
            "maxItems": 24,
            "minItems": 0
          },
          "excludeResources": {
            "type": "string",
            "description": "The list of resources excluded from the depot.\n\nUse this constraint to specify a list of resources that cannot use the depot.\n\n**Type:** string array.\n\n**Default:** Empty array: no resource is excluded from the depot."
          },
          "fixedLoadingDuration": {
            "type": "string",
            "description": "Time, can be expressed in minutes or in hh:mm:ss format."
          },
          "id": {
            "type": "string",
            "description": "The unique identifier of the depot."
          },
          "loadingDurationPerUnit": {
            "type": "string",
            "description": "Time, can be expressed in minutes or in hh:mm:ss format."
          },
          "openingDays": {
            "type": "array",
            "description": "The depot days of opening, related to the nth depot time window.\n\nUse this constraint to specify the days of operation of a depot referring to a depot time window. It must be related to the tsResourceWorkDays constraint of the resources, as resources work days define the planning period. Depot may be opened on a 64-day long period max, from day 1 to day 64.\n\n**Type:** string value containing days separated with commas (like \"1, 2, 5\" or \"4, 20/05/2010\") or intervals (like \"1-10\", \"2=>5\" or \"22/05/2010=>03/06/2010\"). For day intervals, prefer the \"=>\" separator. 1 is the first day of the planning period, the corresponding date, if any, is defined by the oldest date, for all resources, in the tsResourceWorkDays constraint. No date in the depots days of opening description can precede the first day of the planning period defined by the resources (which is day 1). **Default:** 1=>64.\n\n**Example:**\n\n* Set it to \"1\" (or \"14/05/2010\") when a depot is opened on the first day of the planning period. Set it to \"1, 2, 4, 5\" (or \"14/05/2010,15/05/2010,17/05/2010,18/05/2010\") if the depot may not be visited on the third day of a five-day planning period.\n\n* Set it to \"1=>5\" (or \"14/05/2010=>18/05/2010\") to define a 5-day long period during which the depot is opened.",
            "items": {
              "type": "string"
            },
            "xml": {
              "wrapped": true
            }
          },
          "pickupQuantities": {
            "type": "array",
            "description": "The available space for a product at the depot.\nYou can specify up to 24 values.\n\n**Type:** float array",
            "items": {
              "type": "integer",
              "format": "int32"
            },
            "maxItems": 24,
            "minItems": 0
          },
          "priority": {
            "type": "integer",
            "format": "int32",
            "description": "Depot priority.\nUse this constraint to specify a priority on the depot.\nIf two depots are nearby, the system considers the one with the highest priority.\n\n**Type:** integer"
          },
          "requiredProducts": {
            "type": "string",
            "description": "The list of products a depot contains.\nUse this constraint when a depot must be assigned to a specific\nkind of resource: these resources will need to provide the required\nproducts to be able to load at the depot.\n\n**Type:** string (as a list of products separated with commas).\n\n**Default:** none"
          },
          "resourceNames": {
            "type": "string",
            "description": "Lists the resources that can use the depot.\n\n**Type:** string array.\n\n**Default:** Empty array: no resource can use the depot.\n\n**Example:** Specify [\"Vehicle 1\", \"Vehicle 2\"] to allow only the resources with tags \"Vehicle 1\" and \"Vehicle 2\" to use the depot."
          },
          "supportedProducts": {
            "type": "string",
            "description": "The list of products a depot can receive.\nUse this constraint when a depot must be assigned to a specific\nkind of order (TSORDERPROVIDEDPRODUCTS constraint): these orders will need to provide the specified\nproducts to be able to drop at the depot.\n\n**Type:** string (as a list of products separated with commas).\n\n**Default:** none"
          },
          "timeWindows": {
            "type": "array",
            "description": "The depot time windows.\n\nUse this constraint to specify a depot time window during which the depot is opened. A depot time window is defined by its start time, its end time and days of opening. The start time of a depot time window is the first instant when a resource can enter the depot. Its end time is the last instant when a resource can enter the depot (but it may leave it afterward). You can specify up to 10 depot time windows for each depot.\n\n**Type:** \"hh:mm:ss\", DateTime. **Default:** \"00:00:00\".",
            "items": {
              "$ref": "#/components/schemas/TSTimeWindow"
            },
            "xml": {
              "wrapped": true
            }
          },
          "travelTimeModifier": {
            "$ref": "#/components/schemas/TSTravelTimeModifier"
          },
          "x": {
            "type": "number",
            "format": "double",
            "description": "Longitude WGS84 of the depot."
          },
          "y": {
            "type": "number",
            "format": "double",
            "description": "Latitude WGS84 of the depot."
          }
        },
        "required": [
          "id",
          "x",
          "y"
        ]
      },
      "TSTimeWindow": {
        "type": "object",
        "description": "Time window expressed with a begin and end times",
        "properties": {
          "beginTime": {
            "type": "string",
            "description": "Time, can be expressed in minutes or in hh:mm:ss format."
          },
          "endTime": {
            "type": "string",
            "description": "Time, can be expressed in minutes or in hh:mm:ss format."
          }
        },
        "xml": {
          "name": "timeWindow"
        }
      },
      "TSTravelTimeModifier": {
        "type": "object",
        "description": "Indicates the value of the travel time modifier.\r\nWhen reaching a location situated in a large city, one may want to take\r\ninto account driving difficulties, such as narrow streets and congestion.\r\nThe travel time modifier enables to increase the travel times around a\r\nlocation. It is described by three values. The value by which multiply\r\nthe travel times around the location (tsOrderTravelTimeModifierValue),\r\nthe portion of the travel time on which the modifier applies\r\n(tsOrderTravelTimeModifierLength) an offset to add to any travel duration\r\nleaving or reaching the location (tsOrderTravelTimeModifierOffSet).\r\n**Example:**\r\n* Set tsOrderTravelTimeModifierValue to 1.5,\r\ntsOrderTravelTimeModifierLength to 300 and\r\ntsOrderTravelTimeModifierOffSet to 60 for Order 1.\r\n* Set tsOrderTravelTimeModifierValue to 2,\r\ntsOrderTravelTimeModifierLength to 420 and\r\ntsOrderTravelTimeModifierOffSet to 0 for Order 2. If the initial travel\r\nduration between Order 1 and Order 2 was 1000, one obtains a travel time\r\n360 * 1.5 + 60 + 280 + 420 * 2 + 0 = 1660.\r\n**Type:** float.\r\n**Default:** 1.",
        "properties": {
          "length": {
            "type": "string",
            "description": "Time, can be expressed in minutes or in hh:mm:ss format."
          },
          "offset": {
            "type": "string",
            "description": "Time, can be expressed in minutes or in hh:mm:ss format."
          },
          "value": {
            "type": "number",
            "format": "double",
            "description": "Indicates the value of the travel time modifier.\n\nWhen reaching a location situated in a large city, one may want to take into account driving difficulties, such as narrow streets and congestion.\n\nThe travel time modifier enables to increase the travel times around a location. It is described by three values. The value by which multiply the travel times around the location (tsDepotTravelTimeModifierValue), the portion of the travel time on which the modifier applies (*length*) an offset to add to any travel duration leaving or reaching the location (*offSet*).\n\n**Example:**\n\n* Set tsResource TravelTimeModifier Value to 1.5, tsResource TravelTime Modifier Length to 300 and tsResource TravelTimeModifier OffSet to 60 for Resource 1\n\n* Set tsDepot TravelTimeModifier Value to 2, tsDepot TravelTimeModifier Length to 420 and tsDepot TravelTimeModifier OffSet to 0 for Depot 1\n\nIf the initial travel duration between Resource 1 and Depot 1 was 1000, one obtains a travel time 360 * 1.5 + 60 + 280 + 420 * 2 + 0 = 1660\n\n**Type:** float \n\n**Default:** 1"
          }
        }
      }
    },
    "securitySchemes": {
      "apiKey": {
        "description": "The api key can be passed through an header or in the query.",
        "in": "header",
        "name": "apiKey",
        "type": "apiKey"
      }
    }
  }
}
```