SavePartnerLocations (POST)

Overview

This POST API can be used to capture new additions partner location details from ERP into GEP SMART, that can be used as reference in P2P transactions.

 

URL Format: https://<Instance>/smartInterfaceAPI/api/Partner/Locations

Request
[
 {
 "gepLocationCode": 0,
 "locationCode": "string",
 "locationName": "string",
 "address": {
 "addressLine1": "string",
 "addressLine2": "string",
 "addressLine3": "string",
 "city": "string",
 "stateCode": "string",
 "stateOther": "string",
 "countryCode": "string",
 "zipCode": "string",
 "faxNo": "string",
 "phoneNo": "string",
 "phoneOther": "string",
 "phoneExtension": "string",
 "phoneOtherExtension": "string",
 "county": "string",
 "poBoxNumber": "string"
 },
 "isDeleted": true,
 "locationType": [
 "None"
 ],
 "locationTypes": [
 "string"
 ],
 "partnerContact": [
 {
 "userName": "string",
 "gepContactCode": 0,
 "contactCode": "string",
 "partnerCode": "string",
 "address": {
 "addressLine1": "string",
 "addressLine2": "string",
 "addressLine3": "string",
 "city": "string",
 "stateCode": "string",
 "stateOther": "string",
 "countryCode": "string",
 "zipCode": "string",
 "faxNo": "string",
 "phoneNo": "string",
 "phoneOther": "string",
 "phoneExtension": "string",
 "phoneOtherExtension": "string",
 "county": "string",
 "poBoxNumber": "string"
 },
 "firstName": "string",
 "lastName": "string",
 "emailAddress": "string",
 "timeZone": "string",
 "locations": [
 null
 ],
 "isPrimary": true,
 "isActive": true,
 "isDeleted": true,
 "userActivities": [
 {
 "activityName": "NONE"
 }
 ],
 "sourceSystemDetails": [
 {
 "name": "string",
 "value": "string"
 }
 ],
 "cultureCode": "string",
 "contactTrackingTypeName": [
 "string"
 ]
 }
 ],
 "engagementModel": [
 {
 "entityCode": "string",
 "entityType": "string",
 "engagementType": [
 "string"
 ],
 "lobEntityCode": "string"
 "locationType": "string",
 "status": "string",
 "isDelete": true
 }
 ],
 "sourceSystemDetails": [
 {
 "name": "string",
 "value": "string"
 }
 ],
 "otherIdentificationTypes": [
 {
 "identificationType": "NONE",
 "identificationNumber": "string"
 }
 ],
 "linkedLocationDetails": [
 {
 "linkedGEPLocationID": 0,
 "sourceSystemDetails": [
 {
 "name": "string",
 "value": "string"
 }
 ],
 "gepLocationID": 0,
 "locationCode": "string",
 "isDeleted": true
 }
 ],
 "bankingStatus": "string",
 "paymentMethod": "string",
 "contactRole": [
 "string"
 ],
 "isDefault": true,
 "bankingInfo": [
 {
 "bankName": "string",
 "beneficiaryName": "string",
 "bankBranch": "string",
 "country": "string",
 "bankAccountNumber": "string",
 "swift_BIC": "string",
 "iban": "string",
 "bankKey_ABA": "string",
 "chipUid": "string",
 "accountTypeName": "string",
 "paymentMethodName": "string",
 "isDeleted": true,
 "fikCode": "string",
 "factoringCompanyName": "string",
 "factoringCompanyCVR": "string",
 "comments": "string"
 }
 ],
 "paymentTerms": [
 {
 "paymentTermName": "string",
 "isDefault": true,
 "paymentTermCode": "string",
 "orgEntities": [
 {
 "entityCode": "string",
 "isDefault": true,
 "entityType": "string",
 "lobEntityCode": "string"
 }
 ],
 "lobEntityCode": "string"
 }
 ],
"partnerLocationCurrencyList": [
 "string"
 ],
 "shippingDetails": [
 {
 "lobEntityCode": "string",
 "fobCode": "string",
 "fobDesciption": "string",
 "locationCode": "string",
 "locationDescription": "string",
 "orgEntities": [
 {
 "entityCode": "string",
 "isDefault": true,
 "entityType": "string",
 "lobEntityCode": "string"
 }
 ]
 }
 ],
 "contactRoleMapping": [
 {
 "contactCode": "string",
 "contactEmailAddress": "string",
 "contactRole": [
 "string"
 ]
 }
 ]
 }
 ]
 }
]

 

Response
{
 "data": {},
 "statusCode": "string",
 "errorDetails": [
 {
 "key": "string",
 "errors": [
 {
 "errorCode": "string",
 "errorDescription": "string"
 }
 ]
 }
 ],
 "successDetails": [
 {
 "key": "string"
 }
 ]
}

 

Examples

Success Scenario - Request
Below request only contains the mandatory attributes.

[
   {
      “locationCode”: “CM988-098”,
      “locationName”: “Avian_TestRequired”,
      “address”: {
         “addressLine1”: “string1”,
         “city”: “LOC City1”,
         “stateCode”: “MH”,
         “countryCode”: “US”,
         “zipCode”: “23109”
      }
   }
]

Success Scenario - Response

{
   "data": null,
   "statusCode": "200",
   "errorDetails": [],
   "successDetails": [
      {
         "key": "Avian_Test"
      }
   ]
}

Error Scenario 1 – Request
Below request contains a missing value of the mandatory attribute- LocationNumber

[
   {
      “locationCode”: “CM988-098”,
      “address”: {
         “addressLine1”: “string1”,
         “city”: “LOC City1”,
         “stateCode”: “MH”,
         “countryCode”: “US”,
         “zipCode”: “23109”
      }
   }
]

Error Scenario 1 – Response

{
   "data": null,
   "statusCode": "400",
   "errorDetails": [
      {
         "key": "CM988-098",
         "errors": [
            {
               "errorCode": "MandatoryField",
               "errorDescription": "LocationName is Mandatory"
            }
         ]
      }
   ],
   "successDetails": []
}

Error Scenario 2 – Request
Below request contains an invalid format of ZipCode and CountryCode.

[
   {
      “locationCode”: “CM988-098”,
      “locationName”: “Avian_Test_3”,
      “address”: {
         “addressLine1”: “string1”,
         “city”: “LOC City1”,
         “stateCode”: “MTK”,
         “countryCode”: “TWUY”,
         “zipCode”: “23109234342342”
      }
   }
]

Error Scenario 2 – Response

{
   "data": null,
   "statusCode": "400",
   "errorDetails": [
      {
         "key": "CM988-098",
         "errors": [
            {
               "errorCode": "LengthValidation",
               "errorDescription": "Max Length for CountryCode is 2"
            },
            {
               "errorCode": "LengthValidation",
               "errorDescription": "Max Length for ZipCode is 10"
            },
            {
               "errorCode": "MandatoryField",
               "errorDescription": "Invalid Country code"
            }
         ]
      }
   ],
   "successDetails": []
}

 

Data Elements

 

Location

Property

Required?

Data type

Description

Validations / Exceptions

LocationCode

Yes

String(100)

Location code of this location

·       Invalid Client Location Code.

·       Location are mapped to another vendor.

·       Client Location Code can map with only one partner.

·       LocationCode is Mandatory.

Max Length for LocationCode is 50.

LocationName

Yes

String(100)

Name of this location

·       LocationName is Mandatory.

Max Length for LocationName is 100.

isDefault

No

Boolean

Status of location if this location is default or not

 

GEPLocationCode

No

Long

GEP location code of the entity

 

This field is only available on Outbound and not on Inbound

 

Address

No

Address object

Check Data Type Address for details

 

IsDeleted

No

Boolean

Visibility status of the entity on whether it should be visible on the application or not

 

LocationType

No

List of LocationType Enum

An Array of location types. The list of location types that are available to select are as follows; “None”, “Remit To Location”, “Ordering Location”, “Solicitation Location”, “Invoicing Location”, “Other”

 

Note: The values in this field are case sensitive

 

LocationTypes

No

List of string

 

·       Invalid Location Type

PartnerContact

No

List of PartnerContact object

Check Data Type Partner Contact for details

 

This field is only available on Outbound and not on Inbound

 

EngagementModel

No

List of EngagementEntityDetail object

Check Data Type Engagement Entity Detail for details

 

SourceSystemDetails

No

List of SourceSystemDetails object

An array of strings that contain information on source systems of location data

 

 

OtherIdentificationTypes

No

List of OtherIdentificationType object

Check Data type Other Identification type for Details

 

LinkedLocationDetails

No

List of LinkedLocationDetails object

Check Data Type Linked Location Details for details

 

BankingStatus

No

String

 

 

PaymentMethod

No

String

 

 

ContactRole

No

List of string

Any array of contact role

 

BankingInfo

No

List of PartnerBankingInformations object

Check Data Type Partner Banking Information’s for details

 

PaymentTerms

No

List of PaymentTerm object

PaymentTerm

 

PartnerLocationCurrencyList

 

List of Location currency

Partner Location currency

 

ShippingDetails

 

List of ShippingDetails object

Check Data Type ShippingDetails for details

 

 

ContactRoleMapping

 

List of Contact role mapping object

Check contact role mapping details

 

 

Address

Property

Required?

Data type

Description

Validations / Exceptions

AddressLine1

Yes

String (500)

Address line 1 of the entity

·       AddressLine1 is Mandatory.

Max Length for AddressLine1 is 500.

StateCode

Yes

String (10)

State code of the entity

·       StateCode is Mandatory.

·       Max Length for StateCode is 1.10.

·       Invalid State.

CountryCode

Yes

String (2)

Country code of the entity

·       CountryCode is Mandatory.

·       Max Length for CountryCode is 1.

·       Invalid Country.

ZipCode

Yes

String (10)

Zip code of the entity

·       ZipCode is Mandatory.

·       Max Length for ZipCode is 1.10.

AddressLine2

No

String (100)

Address line 2 of the entity

·       Max Length for AddressLine2 is 500.

AddressLine3

No

String (100)

Address line 3 of the entity

·       Max Length for AddressLine3 is 100.

City

No

String (50)

City of the entity

·       Max Length for City is 50.

FaxNo

No

String (20)

Fax number of the entity

·       Max Length for FaxNo is 20.

·       Special characters and spaces are not allowed for Fax number except these +(-./ )#@&

PhoneExtension

No

String (5)

Phone extension of the entity

·       Max Length for Phone extension is 1.10.

PhoneNo

No

String (20)

Phone number of the entity

·       Max Length for PhoneNo is 50.

·       Special characters and spaces are not allowed for Phone except these +(-./ )#@&

PhoneOther

No

String (20)

Phone 2 of the entity

·       Max Length for PhoneOther is 20.

·       Special characters and spaces are not allowed for PhoneOther except these +(-./ )#@&

PhoneOtherExtension

No

String (5)

Phone 2’s extension of the entity

·       Max Length for Phone other extension is 10

StateOther

No

String (15)

State name (in case of others) of the entity

·       Max Length for State other is 50

PoBoxNumber

No

String

 

·        

County

No

String (50)

County of the address

·       Max Length for County is 50.

 

PartnerContact

Property

Required?

Data type

Description

Validations / Exceptions

ContactCode

Yes

String(100)

Contact code of the partner contact

·       ContactCode is Mandatory.

Max Length for ContactCode is 100.

FirstName

Yes

String(50)

First name of the partner contact

·       FirstName is Mandatory.

·       Max Length for FirstName is 50

·       Special characters are not allowed for FirstName except these (@&-_ #/.)',

EmailAddress

Yes

String(100)

Email address of the partner contact

·       Email Address is Mandatory.

·       Max Length for EmailAddress is 100.

·       Invalid Email Address.

UserName

No

String(100)

Username of the partner contact

·       UserName is Mandatory.

·       Max Length for UserName is 100

·       Special characters and spaces are not allowed for UserName (except these _.@-),

GEPContactCode

No

Long

GEP contact code of the partner contact

 

This field is available only on Outbound and not on Inbound

 

PartnerCode

No

String(100)

Partner code of the partner to which this contact belongs

·       Max Length for PartnerCode is 100.

Address

No

Address object

Check Data Type Address for details

·        

LastName

No

String(50)

Last name of the partner contact

·       Max Length for LastName is 30

·       Special characters are not allowed for LastName except these (@&-_ #/.)',

TimeZone

No

String(100)

Partner code of the partner to which this contact belongs

·       Max Length for TimeZone is 100.

·       Invalid Timezone if time zone is invalid.

Locations

No

List of Location object

Check Data Type Location for details

 

IsPrimary

No

Boolean

Status of the partner contact if this contact is the primary contact or not

 

IsActive

No

Boolean

Status of the partner contact if active or not

 

IsDeleted

No

Boolean

Visibility status of the partner contact if visible on the application platform of not

 

UserActivities

No

List of Activity object

Check Data Type Activity for details

 

SourceSystemDetails

No

List of SourceSystemDetails object

An array of strings that contain information on source systems of contact data

 

CultureCode

No

String

Culture Code of partner

·       Invalid Culture Code

ContactTrackingTypeName

No

List of String

Contact Tracking Type Name

 

 

UserActivities

Property

Required?

Data type

Description

Validations / Exceptions

ActivityName

No

Activities Enum

One of the following values will be provided in this field; “NONE”, “ADMINISTRATION”, “HOME”, “VIEW_GEPICENTER etc.

 

 

 

SourceSystemDetails

Property

Required?

Data type

Description

Validations / Exceptions

Name

Yes

String

Source system name

·       Invalid Source System Name

Value

Yes

String

Source system value

·       Source System value is Mandatory

 

EngagementModel

Property

Required?

Data type

Description

Validations / Exceptions

EntityCode

No

String

Entity Code of entity

 

EntityType

No

String

Entity type of entity

 

EngagementType

No

List of String

Engagement Type of entity

 

LobEntityCode

No

String

Lob Entity Code of entity

 

 

OtherIdentificationType

Property

Required?

Data type

Description

Validations / Exceptions

IdentificationNumber

No

String(30)

Identification number of the entity

·       IdentificationNumber is mandatory.

Max length for IdentificationNumber is 30.

IdentificationType

No

IdentificationType Enum

One of the following values will be provided in this field; “NONE”, “US_FEDERAL_TAX_ID_EIN_NUMBER”, “SOCIAL_SECURITY_NUMBER”, “VAT_REGISTRATION_NUMBER”, “GST_QST_HST”, “LEI”, “SIC_CODE”, “NACIS_CODE”, “TIN_NUMBER”.

 

Note: The values in this field are case sensitive

 

 

LinkedLocationDetails

Property

Required?

Data type

Description

Validations / Exceptions

LinkedGEPLocationID

No

Long

GEP Linked Location Id

 

SourceSystemDetails

 

No

List of SourceSystemDetails object

Check data type Source System Details for details

 

GEPLocationID

No

Long

GEP Location Id

 

isDeleted

No

Boolean

Visibility status of the entity on whether it should be visible on the application or not

 

LocationCode

No

String

Location code of linked location

 

 

BankingInfo

Property

Required?

Data type

Description

Validations / Exceptions

BankName

No

String

Bank Name of the entity

 

BeneficiaryName

No

String

Beneficiary Name of the entity

 

BankBranch

No

String

Bank Branch of the entity

 

Country

No

String

Country name of the entity

 

BankAccountNumber

No

String

Bank Account Number of the entity

 

Swift_BIC

No

String

Swift BIC

 

IBAN

No

String

IBAN

 

BankKey_ABA

No

String

Bank key ABA

 

ChipUid

No

String

Chip uid

 

AccountTypeName

No

String

Account Type Name of entity

 

PaymentMethodName

No

String

Payment Method Name

 

IsDeleted

No

Boolean

Visibility status of the entity on whether it should be visible on the application or not

 

FIKCode

No

String

FIK Code

 

FactoringCompanyName

No

String

Factoring Company Name

 

FactoringCompanyCVR

No

String

Factoring Company CVR

 

Comments

No

String

Comments

 

 

PaymentTerms

Property

Required?

Data type

Description

Validations / Exceptions

PaymentTermName

No

String

The name of the payment term

 

IsDefault

No

Boolean

Status of the payment term if this payment term is default or not

 

PaymentTermCode

No

String

The code of the payment term

 

OrgEntities

No

List of OrgEntity object

Check data type OrgEntity for details

 

LobEntityCode

No

String

LobEntityCode of the payment term

 

 

OrgEntities

Property

Required?

Data type

Description

Validations / Exceptions

EntityCode

No

String

Entity Code of entity

Invalid Entity Code

IsDefault

No

Boolean

Status of the entity if this is default or not

 

EntityType

No

String

Entity Type of entity

 

LOBEntityCode

No

String

LOB Entity Code of entity

 

 

ShippingDetails

Property

Required?

Data type

Description

Validations / Exceptions

LOBEntityCode

 

String

LOB Entity Code for shipping (Line of business)

 

FOBCode

 

String

FOB Code for shipping

 

FOBDescription

 

String

FOB Description for shipping

 

LocationCode

 

String

Location Code for shipping

 

LocationDescription

 

String

Location Description for shipping

 

OrgEntities

 

List of OrgEntity object

Check data type OrgEntity for details

 

 

ContactRoleMapping

Property

Required?

Data type

Description

Validations / Exceptions

ContactCode

 

String

Contact code

 

ContactEmailAddress

 

String

Contact Email Address

 

ContactRole

 

List of Contact role

Check data contact role