# Data package version

{% hint style="warning" %}

### API test authentication

The Open API block allows you to test OS APIs directly from the page with example data and parameters. To use this feature, you will need to add your API Key or OAuth2 token to the authentication field.

For help generating an API Key or OAuth2 token, please see the [Getting started with an API project](https://docs.os.uk/os-apis/core-concepts/getting-started-with-an-api-project) or [OAuth2 documentation](https://docs.os.uk/os-apis/accessing-os-apis/oauth-2-api).
{% endhint %}

## GET /dataPackages/{dataPackageId}/versions

> Get the list of versions for a specific data package.

```json
{"openapi":"3.0.0","info":{"title":"Ordnance Survey Download API","version":"1.0.0"},"tags":[{"name":"Data Packages","description":"Operations providing access to data packages.\nTo access data packages you must supply a valid API key or OAuth 2 access token.\n"}],"servers":[{"url":"https://api.os.uk/downloads/v1/"}],"security":[{"OAuth2":[]},{"APIKeyQuery":[]},{"APIKeyHeader":[]}],"components":{"securitySchemes":{"OAuth2":{"type":"oauth2","flows":{"clientCredentials":{"tokenUrl":"https://api.os.uk/oauth2/token/v1","scopes":{}}}},"APIKeyQuery":{"type":"apiKey","in":"query","name":"key"},"APIKeyHeader":{"type":"apiKey","in":"header","name":"key"}},"parameters":{"dataPackageId":{"name":"dataPackageId","in":"path","description":"The id of the data package.","required":true,"schema":{"type":"string"}}},"schemas":{"DataPackageVersionSummary":{"type":"object","description":"Summary information about a data package version.\n","required":["id","url","createdOn","reason","supplyType","productVersion","productFormat"],"properties":{"id":{"type":"string"},"url":{"type":"string","format":"uri"},"createdOn":{"type":"string","format":"date"},"reason":{"type":"string","enum":["INITIAL","UPDATE","EXPANSION","RESUPPLY","ONLINE_ORDER"]},"supplyType":{"type":"string","enum":["FULL","COU"]},"productVersion":{"type":"string"},"format":{"type":"string"},"dataPackageUrl":{"type":"string","format":"uri"}}}},"responses":{"UnauthorizedError":{"description":"The API key or OAuth 2 access token is missing or invalid.","content":{"application/json":{"schema":{"type":"object","required":["message"],"properties":{"message":{"type":"string"}}}}}},"NotFoundError":{"description":"The request does not match any known content.\nThe response will contain a human readable message, and may also contain links to help you\nnavigate to other API endpoints.\n","content":{"application/json":{"schema":{"type":"object","required":["message"],"properties":{"message":{"type":"string"},"dataPackagesUrl":{"type":"string","format":"uri"},"downloadCatalogueUrl":{"type":"string","format":"uri"},"productUrl":{"type":"string","format":"uri"},"productDownloadsUrl":{"type":"string","format":"uri"}}}}}}}},"paths":{"/dataPackages/{dataPackageId}/versions":{"get":{"summary":"Get the list of versions for a specific data package.","tags":["Data Packages"],"parameters":[{"$ref":"#/components/parameters/dataPackageId"}],"responses":{"200":{"description":"A list of data package versions.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DataPackageVersionSummary"}}}}},"401":{"$ref":"#/components/responses/UnauthorizedError"},"404":{"$ref":"#/components/responses/NotFoundError"}}}}}}
```
