curl --location 'https://stg-gateway.invora.app/api/v2/marketplace/connections/complete' \
--header 'Content-Type: application/json' \
--data '{
"providerId": "string",
"codeExchange": {
"connectionId": "string",
"authorizationCode": "string",
"state": "string"
},
"webhookToken": {
"merchantId": "string",
"accessToken": "string",
"refreshToken": "string",
"tokenExpiresAt": "2019-08-24T14:15:22.123Z",
"storeId": "string",
"storeName": "string",
"scopes": [
"string"
]
},
"apiKey": {
"apiKey": "string",
"storeId": "string",
"storeName": "string"
},
"syncConfig": {
"defaultBranchId": "string",
"autoFreeze": true,
"autoPushInvoice": true,
"triggerOrderStatuses": [
"string"
],
"providerConfig": {},
"branchMappings": [
{
"providerBranchId": "string",
"providerBranchName": "string",
"invoraBranchId": "string",
"autoMapped": true
}
],
"backfillFromDate": "2019-08-24",
"lastAppliedAt": "2019-08-24T14:15:22.123Z"
}
}'{
"details": {
"connectionId": "string",
"concurrencyStamp": "string",
"providerId": "string",
"providerName": "string",
"status": "CONNECTION_STATUS_UNSPECIFIED",
"authMethod": "AUTH_METHOD_UNSPECIFIED",
"storeId": "string",
"storeName": "string",
"storeUrl": "string",
"syncConfig": {
"defaultBranchId": "string",
"autoFreeze": true,
"autoPushInvoice": true,
"triggerOrderStatuses": [
"string"
],
"providerConfig": {},
"branchMappings": [
{
"providerBranchId": "string",
"providerBranchName": "string",
"invoraBranchId": "string",
"autoMapped": true
}
],
"backfillFromDate": "2019-08-24",
"lastAppliedAt": "2019-08-24T14:15:22.123Z"
},
"syncEnabled": true,
"totalOrdersSynced": "string",
"totalInvoicesPushed": "string",
"lastSyncAt": "2019-08-24T14:15:22.123Z",
"lastError": "string",
"tokenExpiresAt": "2019-08-24T14:15:22.123Z",
"webhookHealth": {
"webhookRegistered": true,
"lastWebhookReceivedAt": "2019-08-24T14:15:22.123Z",
"consecutiveFailures": 0,
"providerWebhookId": "string"
},
"providerSubscriptionStatus": "PROVIDER_SUBSCRIPTION_STATUS_UNSPECIFIED",
"providerSubscriptionId": "string",
"audit": {
"creationInfo": {
"createdAt": "2019-08-24T14:15:22.123Z",
"creatorId": "string"
},
"lastModificationTime": "2019-08-24T14:15:22.123Z",
"lastModifierId": "string"
}
}
}