SaveShipToLocation (POST)

Overview

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

 

URL Format: https://<Instance>/SmartInterfaceAPI/api/Ship ToLoction/ShipToLocationDetails

Request
      {
         "shiptoLocationName": " String",
         "shiptoLocationNumber": " String",
         "addressLine1": " String",
         "addressLine2": "String",
         "addressLine3": "String",
         "city": " String",
         "stateCode": "String",
         "zip": " String",
         "countryCode": "String",
         "isDeleted": true,
         "stateOther": "String",
         "lobEntityCode": " String",
         "lstOrgEntity": [
            {
               "entityCode": " String",
               "isDefault": true,
               "entityType": " String",
               "lobEntityCode": "String"
            }
         ]
      }

 

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

 

Examples

Success Scenario - Request 
Request below describes that this contains only the mandatory attributes:

[
   {
      "ShiptoLocationName": "ShiptoName1018201801",
      "ShiptoLocationNumber": "ShiptoNumber1018201801",
      "AddressLine1": "AddressLine1",
      "AddressLine2": "AddressLine2",
      "AddressLine3": "AddressLine3",
      "City": "New York",
      "StateCode": "AK",
      "Zip": "12345",
      "CountryCode": "US",
      "IsDeleted": false,
      "StateOther": "StateOther1",
      "LOBEntityCode": "KNA-SAP",
      "lstOrgEntity": [
         {
            "EntityCode": "GUBR",
            "IsDefault": true,
            "EntityType": "Company Code",
            "LOBEntityCode": "2823"
         }
      ]
   }
]

Success Scenario - Response 

{
   "data": null,
   "statusCode": "200",
   "errorDetails": [],
   "successDetails": [
      {
         "key": "ShiptoName1018201801"
      }
   ]
}
[
   {
      "ShiptoLocationName": "ShiptoName1018201801",
      "ShiptoLocationNumber": "ShiptoNumber1018201801",
      "AddressLine1": "AddressLine1",
      "AddressLine2": "AddressLine2",
      "AddressLine3": "AddressLine3",
      "City": "New York",
      "StateCode": "AK",
      "Zip": "12345",
      "CountryCode": "US",
      "IsDeleted": false,
      "StateOther": "StateOther1",
      "LOBEntityCode": "KNA-SAP1",
      "lstOrgEntity": [
         {
            "EntityCode": "GUBR",
            "IsDefault": true,
            "EntityType": "Company Code",
            "LOBEntityCode": "2823"
         }
      ]
   }
]
{
   "data": null,
   "statusCode": "400",
   "errorDetails": [
      {
         "key": "ShiptoName1018201801",
         "errors": [
            {
               "errorCode": "DataValidation",
               "errorDescription": "Validation: Invalid LOBEntityCode : KNA-SAP1"
            }
         ]
      }
   ],
   "successDetails": []
}

 

Data Elements
 

Save Ship to Location

S.No.

Property

Required?

Data type

Description

Validations/Exceptions

1

ShiptoLocationName

Yes

String

Name of this Ship to location

  • ShiptolocationName is mandatory

  • Max length for ShiptoLocationName is 100

2

ShiptoLocationNumber

Yes

String

Number of this Ship to location

  • ShiptolocationNumber is mandatory

  • Max length for ShiptoLocationNumber is 100

3

AddressLine1

Yes

String

Address line 1 of the entity

  • AddressLine1 is mandatory

  • Max length for AddressLine1 is 500

4

City

Yes

String

City of the entity

  • City is mandatory

  • Max length for City is 50

5

StateCode

Yes

String

State code of the entity

  • StateCode is mandatory

  • Max length for StateCode is 10

6

Zip

Yes

String

Zip code of the entity

  • Zip is mandatory

  • Max length for Zip is 10

7

CountryCode

Yes

String

Country code of the entity

  • CountryCode is mandatory

  • Max length for CountryCode is 2

  • Invalid Country

8

AddressLine2

No

String

Address line 2 of the entity

  • Max length for AddressLine2 is 100

9

AddressLine3

No

String

Address line 3 of the entity

  • Max length for AddressLine2 is 100

10

IsDeleted

No

Bool

A flag used to denote if the Ship to location is the default Ship to location or not

 

11

StateOther

No

String

State which is different from the list of states provided

 

12

LOBEntityCode

No

String

Line of Business Code for ShipToLocation

  • Invalid LOB Entity Code.

13

LstOrgEntity

No

List of OrgEntity object

Check data type OrgEntity for details

 
 

LstOrgEntity

S.No.

Property

Required?

Data type

Description

Validations/Exceptions

13.1

EntityCode

No

String

Entity Code of entity

  • Invalid Entity Code

13.2

IsDefault

No

Bool

Status of the entity if this is default or not

 

13.3

EntityType

No

String

Entity Type of entity

 

13.4

LOBEntityCode

No

String

Line of Business Entity Code of entity