Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix issue with get calls caused by latest swagger client #53

Merged
merged 1 commit into from
Feb 24, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 18 additions & 18 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ class TargetCoreAPI {
const sdkDetails = options
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.activities.getActivities(arguments[0], this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
this.sdk.apis.activities.getActivities(arguments[0], this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
.then(response => {
resolve(response)
})
Expand Down Expand Up @@ -172,7 +172,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.abactivity.getABActivity(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
this.sdk.apis.abactivity.getABActivity(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
.then(response => {
resolve(response)
})
Expand All @@ -196,7 +196,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.xtactivity.getXTActivity(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
this.sdk.apis.xtactivity.getXTActivity(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
.then(response => {
resolve(response)
})
Expand Down Expand Up @@ -433,7 +433,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.activity.getChangeLog(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
this.sdk.apis.activity.getChangeLog(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
.then(response => {
resolve(response)
})
Expand All @@ -457,7 +457,7 @@ class TargetCoreAPI {
const sdkDetails = options
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.offers.getOffers(arguments[0], this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V2)))
this.sdk.apis.offers.getOffers(arguments[0], this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V2)))
.then(response => {
resolve(response)
})
Expand All @@ -481,7 +481,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.offer.getOfferById(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V2)))
this.sdk.apis.offer.getOfferById(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V2)))
.then(response => {
resolve(response)
})
Expand Down Expand Up @@ -577,7 +577,7 @@ class TargetCoreAPI {
const sdkDetails = options
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.audiences.getAudiences(arguments[0], this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
this.sdk.apis.audiences.getAudiences(arguments[0], this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
.then(response => {
resolve(response)
})
Expand Down Expand Up @@ -623,7 +623,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.audiences.getAudienceById(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
this.sdk.apis.audiences.getAudienceById(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
.then(response => {
resolve(response)
})
Expand Down Expand Up @@ -693,7 +693,7 @@ class TargetCoreAPI {
const sdkDetails = options
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.properties.getProperties({}, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
this.sdk.apis.properties.getProperties({}, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
.then(response => {
resolve(response)
})
Expand All @@ -717,7 +717,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.properties.getAPropertyById(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
this.sdk.apis.properties.getAPropertyById(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
.then(response => {
resolve(response)
})
Expand All @@ -738,7 +738,7 @@ class TargetCoreAPI {
const sdkDetails = {}
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.mboxes.getMBoxes({}, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
this.sdk.apis.mboxes.getMBoxes({}, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
.then(response => {
resolve(response)
})
Expand All @@ -762,7 +762,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.mboxes.getMBoxByName(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
this.sdk.apis.mboxes.getMBoxByName(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
.then(response => {
resolve(response)
})
Expand All @@ -783,7 +783,7 @@ class TargetCoreAPI {
const sdkDetails = options
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.mbox.getProfileAttributes({}, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
this.sdk.apis.mbox.getProfileAttributes({}, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
.then(response => {
resolve(response)
})
Expand All @@ -804,7 +804,7 @@ class TargetCoreAPI {
const sdkDetails = options
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.environments.getEnvironments({}, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
this.sdk.apis.environments.getEnvironments({}, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V1)))
.then(response => {
resolve(response)
})
Expand All @@ -828,7 +828,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.reports.getABPerformance(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
this.sdk.apis.reports.getABPerformance(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
.then(response => {
resolve(response)
})
Expand All @@ -852,7 +852,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.reports.getXTPerformance(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
this.sdk.apis.reports.getXTPerformance(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
.then(response => {
resolve(response)
})
Expand All @@ -876,7 +876,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.reports.getABTPerformance(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
this.sdk.apis.reports.getABTPerformance(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
.then(response => {
resolve(response)
})
Expand All @@ -900,7 +900,7 @@ class TargetCoreAPI {
const sdkDetails = params
const headers = options.headers ? options.headers : {}
return new Promise((resolve, reject) => {
this.sdk.apis.reports.getAuditReport(params, this.__createRequest({}, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
this.sdk.apis.reports.getAuditReport(params, this.__createRequest(null, headers, this.__getAcceptHeader(ACCEPT_HEADERS.V3)))
.then(response => {
resolve(response)
})
Expand Down