All URIs are relative to https://api.merge.dev/api/ats/v1
Method | HTTP request | Description |
---|---|---|
offersList | GET /offers | |
offersRetrieve | GET /offers/{id} |
PaginatedOfferList offersList(xAccountToken, opts)
Returns a list of `Offer` objects.
import MergeAtsApi from 'merge_ats_api';
let defaultClient = MergeAtsApi.ApiClient.instance;
// Configure API key authorization: tokenAuth
let tokenAuth = defaultClient.authentications['tokenAuth'];
tokenAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//tokenAuth.apiKeyPrefix = 'Token';
let apiInstance = new MergeAtsApi.OffersApi();
let xAccountToken = "xAccountToken_example"; // String | Token identifying the end user.
let opts = {
'applicationId': "applicationId_example", // String | If provided, will only return offers for this application.
'createdAfter': new Date("2013-10-20T19:20:30+01:00"), // Date | If provided, will only return objects created after this datetime.
'createdBefore': new Date("2013-10-20T19:20:30+01:00"), // Date | If provided, will only return objects created before this datetime.
'creatorId': "creatorId_example", // String | If provided, will only return offers created by this user.
'cursor': cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw, // String | The pagination cursor value.
'expand': application,creator, // String | Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
'includeRemoteData': true, // Boolean | Whether to include the original data Merge fetched from the third-party to produce these models.
'modifiedAfter': new Date("2013-10-20T19:20:30+01:00"), // Date | If provided, will only return objects modified after this datetime.
'modifiedBefore': new Date("2013-10-20T19:20:30+01:00"), // Date | If provided, will only return objects modified before this datetime.
'pageSize': 56, // Number | Number of results to return per page.
'remoteId': "remoteId_example" // String | The API provider's ID for the given object.
};
apiInstance.offersList(xAccountToken, opts, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
Name | Type | Description | Notes |
---|---|---|---|
xAccountToken | String | Token identifying the end user. | |
applicationId | String | If provided, will only return offers for this application. | [optional] |
createdAfter | Date | If provided, will only return objects created after this datetime. | [optional] |
createdBefore | Date | If provided, will only return objects created before this datetime. | [optional] |
creatorId | String | If provided, will only return offers created by this user. | [optional] |
cursor | String | The pagination cursor value. | [optional] |
expand | String | Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces. | [optional] |
includeRemoteData | Boolean | Whether to include the original data Merge fetched from the third-party to produce these models. | [optional] |
modifiedAfter | Date | If provided, will only return objects modified after this datetime. | [optional] |
modifiedBefore | Date | If provided, will only return objects modified before this datetime. | [optional] |
pageSize | Number | Number of results to return per page. | [optional] |
remoteId | String | The API provider's ID for the given object. | [optional] |
- Content-Type: Not defined
- Accept: application/json
Offer offersRetrieve(xAccountToken, id, opts)
Returns an `Offer` object with the given `id`.
import MergeAtsApi from 'merge_ats_api';
let defaultClient = MergeAtsApi.ApiClient.instance;
// Configure API key authorization: tokenAuth
let tokenAuth = defaultClient.authentications['tokenAuth'];
tokenAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//tokenAuth.apiKeyPrefix = 'Token';
let apiInstance = new MergeAtsApi.OffersApi();
let xAccountToken = "xAccountToken_example"; // String | Token identifying the end user.
let id = null; // String |
let opts = {
'expand': application,creator, // String | Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
'includeRemoteData': true // Boolean | Whether to include the original data Merge fetched from the third-party to produce these models.
};
apiInstance.offersRetrieve(xAccountToken, id, opts, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
Name | Type | Description | Notes |
---|---|---|---|
xAccountToken | String | Token identifying the end user. | |
id | String | ||
expand | String | Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces. | [optional] |
includeRemoteData | Boolean | Whether to include the original data Merge fetched from the third-party to produce these models. | [optional] |
- Content-Type: Not defined
- Accept: application/json