# Data Exchange API

This API provides services to upload, manipulate and download businesspartner data in the CDL Cloud.

Version: 5

## Servers

Production
```
https://api.cdq.com/data-exchange/rest
```

## Security

### apiKey

Type: apiKey
In: header
Name: X-API-KEY

## Download OpenAPI description

 - [Data Exchange API](https://developer.cdq.com/_bundle/apis/data-exchange-api/@data-exchange-api-v5/api-v5.yaml)

## Seed Updates

 - [POST /v5/storages/{storageId}/seedupdates/generate](https://developer.cdq.com/apis/data-exchange-api/api-v5/seed-updates/paths/~1v5~1storages~1%7Bstorageid%7D~1seedupdates~1generate/post.md): Start a Seed Updates Generate Job for the given storage.
 - [GET /v5/storages/{storageId}/seedupdates/generate/{jobId}](https://developer.cdq.com/apis/data-exchange-api/api-v5/seed-updates/paths/~1v5~1storages~1%7Bstorageid%7D~1seedupdates~1generate~1%7Bjobid%7D/get.md): Poll a Seed Updates Generate Job for the given storage.
## Business Partner Storages

 - [PUT /storages/{storageId}](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D/put.md): Update a Business Partner Storage.
 - [DELETE /storages/{storageId}](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D/delete.md): Delete a Business Partner Storage.
 - [POST /v2/storages/{storageId}/eventstore/roll](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1v2~1storages~1%7Bstorageid%7D~1eventstore~1roll/post.md): **Roll Event Store for Business Partner Storage** This endpoint facilitates the transition to a new event store for Business Partner Storage. The process involves several key steps: **Validation:** En
 - [GET /v5/storages/datamirror](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1v5~1storages~1datamirror/get.md): Read Data Mirror of the current workspace.
 - [POST /storages/{storageId}/clear](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D~1clear/post.md): Remove all Business Partners from given Business Partner Storage.
 - [POST /storages/{storageId}/datasources](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D~1datasources/post.md): Create a new data source. Max 100 data sources are allowed. Warn: If you have an integration with one data source, please check if data source id is included in the upsert request before adding a new
 - [PUT /storages/{storageId}/datasources/{dataSourceId}](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D~1datasources~1%7Bdatasourceid%7D/put.md): Update a Data Source.
 - [DELETE /storages/{storageId}/datasources/{dataSourceId}](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D~1datasources~1%7Bdatasourceid%7D/delete.md): Delete a data source and its dependencies: * Business Partners from a storage, * update monitors, data monitors and sharing scopes for that data source are adjusted (data source is removed from the da
 - [POST /storages/{storageId}/datasources/{dataSourceId}/clear](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D~1datasources~1%7Bdatasourceid%7D~1clear/post.md): Clear all Business Partners of a data source.
 - [POST /storages/{storageId}/datasources/{dataSourceId}/copy](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D~1datasources~1%7Bdatasourceid%7D~1copy/post.md): Copy a data source between storages.
 - [GET /storages/{storageId}/datasources/{dataSourceId}/copy/{jobId}](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D~1datasources~1%7Bdatasourceid%7D~1copy~1%7Bjobid%7D/get.md): Allows polling the status of copy data source job
 - [GET /v2/updatemonitors/referencedatasources](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1v2~1updatemonitors~1referencedatasources/get.md): List all data sources available for update monitoring.
 - [GET /v4/storages/{storageId}/sharingscopes](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1v4~1storages~1%7Bstorageid%7D~1sharingscopes/get.md): List all sharing scopes of the give storage.
 - [POST /v4/storages/{storageId}/sharingscopes](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1v4~1storages~1%7Bstorageid%7D~1sharingscopes/post.md): Create a new sharing scope. Max 100 sharing scopes are allowed. When creating sharing scope, all Business Partners from selection scope which are covered become disclosed. The following table presents
 - [POST /v4/storages/{storageId}/sharingscopes/delete](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1v4~1storages~1%7Bstorageid%7D~1sharingscopes~1delete/post.md): Delete sharing scopes. When deleting sharing scope, all Business Partners from selection scope who are not included in any other sharing scopes, become undisclosed.
 - [PUT /storages/{storageId}/datasources](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D~1datasources/put.md): This endpoint is deprecated. Please use * [create data source](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1storages~1%7Bstorageid%7D~1datasources/post) to
 - [GET /updatemonitors/datasources](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partner-storages/paths/~1updatemonitors~1datasources/get.md): List all data sources available for update monitoring.
## Business Partners

 - [GET /v4/storages/{storageId}/businesspartners](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1v4~1storages~1%7Bstorageid%7D~1businesspartners/get.md): Read a page of business partners from the storage.
 - [PUT /v4/storages/{storageId}/businesspartners](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1v4~1storages~1%7Bstorageid%7D~1businesspartners/put.md): Upsert Business Partners in a Business Partner storage in batches. Maximum of 1000 Business Partners are allowed per batch. If no data source (via field: `dataSource`) is provided and the storage has
 - [GET /v5/storages/{storageId}/businesspartners/updates](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1v5~1storages~1%7Bstorageid%7D~1businesspartners~1updates/get.md): The Read Business Partner Updates endpoint provides an updated Business Partner structure and comprehensive Business Partner information from the Reference Data Sources. By default, only the latest ve
 - [POST /storages/{storageId}/businesspartners/delete](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1storages~1%7Bstorageid%7D~1businesspartners~1delete/post.md): Delete batches of Business Partners by ID or a combination of DataSource and External ID. Maximum of 1000 Business Partners are allowed per batch. In case only a data source is provided in the request
 - [PUT /storages/{storageId}/businesspartners/toggleUpdateMonitoring](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1storages~1%7Bstorageid%7D~1businesspartners~1toggleupdatemonitoring/put.md): To toggle update monitoring on multiple BusinessPartners, the permission can be changed via a list of Business Partners, identified by their ID. After the job is finished, the following actions are ta
 - [POST /jobs/toggleUpdateMonitoringJobs](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1jobs~1toggleupdatemonitoringjobs/post.md): To toggle update monitoring on multiple BusinessPartners, the permission can be changed in two ways: 1. A complete Data Source identified by the parameter 'dataSourceId' 2. Or for a certain Country of
 - [GET /jobs/toggleUpdateMonitoringJobs/{jobId}](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1jobs~1toggleupdatemonitoringjobs~1%7Bjobid%7D/get.md): Poll endpoint for a job created in POST `toggleUpdateMonitoringJobs`.
 - [POST /v3/storages/{storageId}/businesspartners/updateDisclosure](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1v3~1storages~1%7Bstorageid%7D~1businesspartners~1updatedisclosure/post.md): To un-/disclose multiple BusinessPartners, the disclosure can be changed in three ways: 1. A complete data source identified by the parameter 'dataSourceId' (deprecated - use Sharing Scopes instead. S
 - [GET /v4/storages/{storageId}/businesspartners/{id}](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1v4~1storages~1%7Bstorageid%7D~1businesspartners~1%7Bid%7D/get.md): Read Business Partner by ID.
 - [POST /v4/storages/{storageId}/businesspartners/fetch](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1v4~1storages~1%7Bstorageid%7D~1businesspartners~1fetch/post.md): Fetch a Business Partner from this storage.
 - [POST /v4/storages/{storageId}/businesspartners/{businessPartnerId}/profile/tags](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1v4~1storages~1%7Bstorageid%7D~1businesspartners~1%7Bbusinesspartnerid%7D~1profile~1tags/post.md): Allows the creation of Business Partner tags. The tags are created in the Business Partner profile.
 - [POST /v4/storages/{storageId}/businesspartners/{businessPartnerId}/profile/tags/delete](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1v4~1storages~1%7Bstorageid%7D~1businesspartners~1%7Bbusinesspartnerid%7D~1profile~1tags~1delete/post.md): Allows the deletion of Business Partner tags. The tags are deleted from the Business Partner profile.
 - [GET /v4/storages/{storageId}/businesspartners/random](https://developer.cdq.com/apis/data-exchange-api/api-v5/business-partners/paths/~1v4~1storages~1%7Bstorageid%7D~1businesspartners~1random/get.md): Get random Business Partners from this storage.
## Data Import

 - [POST /jobs/importjobs](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-import/paths/~1jobs~1importjobs/post.md): To start importing a file into a storage, use the following request. ``` POST https://api.corporate-data-league.ch/data-exchange/rest/jobs/importjobs ?file=@{YOUR FILE} ?storageId={YOUR STORAGE I
 - [GET /jobs/importjobs/{jobId}](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-import/paths/~1jobs~1importjobs~1%7Bjobid%7D/get.md): Allows polling the status of an Import Job.
## Data Mapping

 - [POST /datamapperdefinitions](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-mapping/paths/~1datamapperdefinitions/post.md): Create a Data Mapper Definition which is used to map data (i.e. in the format from the database) to the CDQ data model. Data mapper definition consists of: * `inputMapping` - definition how to map `bu
 - [GET /datamapperdefinitions](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-mapping/paths/~1datamapperdefinitions/get.md): Read the Data Mapper Definition Page.
 - [GET /datamapperdefinitions/{id}](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-mapping/paths/~1datamapperdefinitions~1%7Bid%7D/get.md): Read a Data Mapper Definition.
 - [PUT /datamapperdefinitions/{id}](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-mapping/paths/~1datamapperdefinitions~1%7Bid%7D/put.md): Update a Data Mapper Definition. For more information what are the allowed Data Mapper values, go to [creation endpoint](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-mapping/paths/~1da
 - [DELETE /datamapperdefinitions/{id}](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-mapping/paths/~1datamapperdefinitions~1%7Bid%7D/delete.md): Delete chosen Data Mapper Definition.
## Data Monitors

 - [GET /v2/datamonitors](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-monitors/paths/~1v2~1datamonitors/get.md): List all Data Monitors of a specific type across all storages.
 - [DELETE /storages/{storageId}/datamonitors/{dataMonitorId}](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-monitors/paths/~1storages~1%7Bstorageid%7D~1datamonitors~1%7Bdatamonitorid%7D/delete.md): Delete a data monitor.
 - [GET /v2/storages/{storageId}/datamonitors](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-monitors/paths/~1v2~1storages~1%7Bstorageid%7D~1datamonitors/get.md): List all Data Monitors of the give storage.
 - [POST /v2/storages/{storageId}/datamonitors](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-monitors/paths/~1v2~1storages~1%7Bstorageid%7D~1datamonitors/post.md): Create a new data monitor. Data monitor is a concept for asynchronous processing of data curation and data validation. Data monitors should be unique by a pair: `dataSources` + `type`. Data monitor ca
 - [PUT /v2/storages/{storageId}/datamonitors/{dataMonitorId}](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-monitors/paths/~1v2~1storages~1%7Bstorageid%7D~1datamonitors~1%7Bdatamonitorid%7D/put.md): Note: modification of `configuration.id` or set of `dataSources` starts background process that populates processing log for all Business Partners from data monitor scope.
 - [GET /v2/storages/{storageId}/datamonitors/{dataMonitorId}/progress](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-monitors/paths/~1v2~1storages~1%7Bstorageid%7D~1datamonitors~1%7Bdatamonitorid%7D~1progress/get.md): Note: modification of `configuration.id` or set of `dataSources` starts background process that populates processing log for all Business Partners from data monitor scope.
 - [POST /v2/storages/{storageId}/datamonitors/refresh](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-monitors/paths/~1v2~1storages~1%7Bstorageid%7D~1datamonitors~1refresh/post.md): Refresh Data Monitors. When refreshing data monitor, a reevaluation is done for all Business Partners from the data monitor scope.
## Data Transformation

 - [POST /jobs/transformationjobs](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-transformation/paths/~1jobs~1transformationjobs/post.md): Starting a Transformation Job. In case any selected data source does not have a `dataMappingDefinition` an API error returned.
 - [GET /jobs/transformationjobs/{id}](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-transformation/paths/~1jobs~1transformationjobs~1%7Bid%7D/get.md): After you have started a transformation job, you will receive a job id in the response. ``` { "id" : "<ID>" } ``` Use this ID to poll for the status of the job using this endpoint. Once the status
 - [POST /v3/datamappers/{id}/transform](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-transformation/paths/~1v3~1datamappers~1%7Bid%7D~1transform/post.md): Use a Data Mapper Definition to transform a list of records into Business Partners.
## DNB Storages

 - [GET /v5/dnbstorages/dnbrecords](https://developer.cdq.com/apis/data-exchange-api/api-v5/dnb-storages/paths/~1v5~1dnbstorages~1dnbrecords/get.md): Read a page of records from the D&B storage of your organization.
 - [POST /jobs/dnbimportjobs](https://developer.cdq.com/apis/data-exchange-api/api-v5/dnb-storages/paths/~1jobs~1dnbimportjobs/post.md): To start a D&B Import Job use the following request ``` curl -X POST \ --url 'https://api.corporate-data-league.ch/data-exchange/rest/jobs/dnbimportjobs?dnbUser=optional&dnbPassword=optional' \ -
 - [GET /jobs/dnbimportjobs/{id}](https://developer.cdq.com/apis/data-exchange-api/api-v5/dnb-storages/paths/~1jobs~1dnbimportjobs~1%7Bid%7D/get.md): After you have started a D&B import job, you will receive a job id in the response. `{ "id" : "<ID>" }` Use this ID to poll for the status of the job using this endpoint. Once the status is FINISHED
 - [POST /jobs/dnbcreatelodjobs](https://developer.cdq.com/apis/data-exchange-api/api-v5/dnb-storages/paths/~1jobs~1dnbcreatelodjobs/post.md): For all data mirrors configured for an organization, read Business Partners identifiers with type `DUNS_ID` and create a list of the DUNS file. This file is used to initialize the D&B Monitoring proce
 - [GET /jobs/dnbcreatelodjobs/{id}](https://developer.cdq.com/apis/data-exchange-api/api-v5/dnb-storages/paths/~1jobs~1dnbcreatelodjobs~1%7Bid%7D/get.md): After you have started a D&B LOD job, you will receive a job id in the response. `{ "id" : "<ID>" }` Use this ID to poll for the status of the job using this endpoint. Once the status is FINISHED, y
 - [POST /v4/dnbstorages/fetch](https://developer.cdq.com/apis/data-exchange-api/api-v5/dnb-storages/paths/~1v4~1dnbstorages~1fetch/post.md): Fetch a D&B record by providing the DUNS.
## Files

 - [POST /v5/files/upload](https://developer.cdq.com/apis/data-exchange-api/api-v5/files/paths/~1v5~1files~1upload/post.md): Create a file in the file storage using the url provided. Maximum allowed file size is 300 MiB.
 - [GET /v5/files](https://developer.cdq.com/apis/data-exchange-api/api-v5/files/paths/~1v5~1files/get.md): Returns a list of all files that are available at the specific url path.
 - [POST /v5/files/download](https://developer.cdq.com/apis/data-exchange-api/api-v5/files/paths/~1v5~1files~1download/post.md): Request a download link for a file stored in CDQ Cloud. Files undergo mandatory malware scanning before they become available for download. The response returns HTTP 200 or 400, depending on scan stat
 - [DELETE /files](https://developer.cdq.com/apis/data-exchange-api/api-v5/files/paths/~1files/delete.md): Delete files in the customer-uploads directory using the provided urls.
 - [GET /files/resources](https://developer.cdq.com/apis/data-exchange-api/api-v5/files/paths/~1files~1resources/get.md): Returns list of all resources, which are available at the specific url path.
## Subscriptions (None Public)

## Data Mappers

 - [POST /v4/datamapperdefinitions/{id}/transformBusinessPartners](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-mappers/paths/~1v4~1datamapperdefinitions~1%7Bid%7D~1transformbusinesspartners/post.md): Use a Data Mapper Definition to transform a list of records into Business Partners.
 - [POST /v4/datamapperdefinitions/{id}/transformFields](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-mappers/paths/~1v4~1datamapperdefinitions~1%7Bid%7D~1transformfields/post.md): Use a Data Mapper Definition to transform a list of Business Partners into key-value lists.
 - [POST /v3/datamappers/{id}/transformBusinessPartners](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-mappers/paths/~1v3~1datamappers~1%7Bid%7D~1transformbusinesspartners/post.md): Use a Data Mapper Definition to transform a list of records into Business Partners.
 - [POST /v3/datamappers/{id}/transformFields](https://developer.cdq.com/apis/data-exchange-api/api-v5/data-mappers/paths/~1v3~1datamappers~1%7Bid%7D~1transformfields/post.md): Use a Data Mapper Definition to transform a list of Business Partners into key-value lists.
## Relations

 - [POST /v4/storages/{storageId}/relations](https://developer.cdq.com/apis/data-exchange-api/api-v5/relations/paths/~1v4~1storages~1%7Bstorageid%7D~1relations/post.md): Initialize relations in a Business Partner Storage.
 - [GET /v4/storages/{storageId}/relations](https://developer.cdq.com/apis/data-exchange-api/api-v5/relations/paths/~1v4~1storages~1%7Bstorageid%7D~1relations/get.md): Read a page of relations from a Business Partner Storage.
 - [PUT /v4/storages/{storageId}/relations](https://developer.cdq.com/apis/data-exchange-api/api-v5/relations/paths/~1v4~1storages~1%7Bstorageid%7D~1relations/put.md): Insert or update Business Partner Relations. Relations that are not listed in the request are not modified. In D&B storages, not-listed relations of class `BUSINESS_PARTNER_RELATION_CLASS_DNB_HIERARCH
 - [POST /v4/storages/{storageId}/relations/delete](https://developer.cdq.com/apis/data-exchange-api/api-v5/relations/paths/~1v4~1storages~1%7Bstorageid%7D~1relations~1delete/post.md): Delete relations from a storage.
## Subscriptions

 - [GET /v4/businesspartners/identitylinks](https://developer.cdq.com/apis/data-exchange-api/api-v5/subscriptions/paths/~1v4~1businesspartners~1identitylinks/get.md): Reads a page of links of the Business Partners starting from the 'startAfter' and with a size of 'limit'.
## Update Classification

## Business Partner Storages (None Public)

## Restart Monitor Job

## Cache

## Configuration

## Event Store

## CDQ Community Pool

## Identity Link

## Event Stores

