getOrganization

get

/ccagent/v1/organizations/{id}

Get Organization. This operation is used to get the Organization information of a customer from Oracle Commerce Cloud. Optionally takes X-CCOrganization header which is a JSON field with organization ID as value. If this header is not provided, then the endPoint will consider first active organization as the current organization.

Request

Supported Media Types
  • application/json
Path Parameters
id
Type: string
Required: true
The ID of the requested Organization.
Header Parameters
X-CCAgentContext
Type: string
Required: true
The Agent Context is a JSON object with shopperProfileId as a property.
X-CCAsset-Language
Type: string
The asset language of the request
X-CCOrganization
Type: string
The organization Id associated with the shopper profile
X-CCSite
Type: string
The site Id to retrieve the site specific organization properties

Response

Supported Media Types
  • application/json
200 Response
Following model is returned when operation succeeds.
Body
Root Schema : getOrganization_response
Nested Schema : billingAddress
Type: object
The default billing address for the Organization. This a read only attribute. This will be returned if the property 'isDefaultBillingAddress' is set to 'true' in secondaryAddresses attribute.
Nested Schema : contract
Type: object
Contract
Nested Schema : derivedBillingAddress
Type: object
The default billing address for the Organization. This a read only attribute. This will be returned if the property 'isDefaultBillingAddress' is set to 'true' in secondaryAddresses attribute.
Nested Schema : derivedPaymentMethods
Type: array
Derived payment methods associated for organization.
Nested Schema : derivedShippingAddress
Type: object
The default shipping address for the Organization. This a read only attribute. This will be returned if the property 'isDefaultShippingAddress' is set to 'true' in secondaryAddresses attribute.
Nested Schema : derivedShippingMethods
Type: array
Derived shipping methods associated for organization.
Nested Schema : paymentMethods
Type: array
Payment methods associated for organization.
Nested Schema : relativeRoles
Type: array
List of roles associated with an Organization
Nested Schema : secondaryAddresses
Type: array
List of all the addresses associated with an Organization, if property like 'isDefaultShippingAddress' or 'isDefaultBillingAddress' is set to 'true', then in response the same address will come as a separate attribute with name 'shippingAddress' or 'billingAddress'.
Nested Schema : shippingAddress
Type: object
The default shipping address for the Organization. This a read only attribute. This will be returned if the property 'isDefaultShippingAddress' is set to 'true' in secondaryAddresses attribute.
Nested Schema : shippingMethods
Type: array
Shipping methods associated for organization.
Nested Schema : catalog
Type: object
Catalog associated with contract
Nested Schema : priceListGroup
Type: object
Price ListGroup associated with contract
Nested Schema : terms
Type: object
Terms and Conditions
Nested Schema : items
Type: object
Nested Schema : items
Type: object
Nested Schema : items
Type: object
Nested Schema : address
Type: object
Address created for the Organization.
Nested Schema : items
Type: object
Example application/json

{
    "taxReferenceNumber":"901-70-7000",
    "organizationLogo":null,
    "description":null,
    "delegateApprovalManagement":false,
    "secondaryAddresses":[
        {
            "address":{
                "country":"US",
                "phoneNumber":"631-748-6479",
                "address2":"Suffolk",
                "city":"Bohemia",
                "address1":"70 Euclid Ave #722",
                "companyName":"National Discount Auto Parts",
                "postalCode":"11716",
                "repositoryId":"ci-110024",
                "state":"NY"
            },
            "addressType":"Address2"
        },
        {
            "address":{
                "country":"US",
                "phoneNumber":"907-385-4412",
                "address2":null,
                "city":"Anchorage",
                "address1":"639 Main St",
                "companyName":"National Discount Auto Parts",
                "postalCode":"99501",
                "repositoryId":"ci-110023",
                "state":"AZ"
            },
            "addressType":"Address1"
        }
    ],
    "type":"company",
    "derivedBillingAddress":{
        "country":"US",
        "phoneNumber":"631-748-6479",
        "address2":"Suffolk",
        "city":"Bohemia",
        "address1":"70 Euclid Ave #722",
        "companyName":"National Discount Auto Parts",
        "postalCode":"11716",
        "repositoryId":"ci-110024",
        "state":"NY"
    },
    "derivedUniqueId":null,
    "customerType":"Standard",
    "organizationLogoURL":null,
    "derivedContract":{
        "endDate":null,
        "terms":{
            "terms":"

Terms and Conditions for contract with National Discount Auto Parts organization

", "repositoryId":"ct-100001" }, "catalog":{ "displayName":"QA Movie and Games Catalog", "repositoryId":"cloudLakeCatalog" }, "displayName":"Contract_NDAP", "repositoryId":"ct-100001", "description":"Contract with National Discount Auto Parts", "priceListGroup":{ "displayName":"Default Price Group", "repositoryId":"defaultPriceGroup" }, "creationDate":"2016-05-04T02:41:00.000Z", "externalContractReference":"Test", "startDate":null }, "members":[ { "repositoryId":"bb-110032" }, { "repositoryId":"bb-110000" }, { "repositoryId":"bb-110033" }, { "repositoryId":"bb-110023" }, { "repositoryId":"bb-110034" }, { "repositoryId":"bb-110006" } ], "derivedBillingAddressType":"Address2", "links":[ { "rel":"self", "href":"http://busgk0105.us.oracle.com:9080/ccagentui/v1/organizations/or-100001" } ], "id":"or-100001", "relativeRoles":[ { "relativeTo":null, "function":"admin", "repositoryId":"100001" }, { "relativeTo":null, "function":"buyer", "repositoryId":"100002" }, { "relativeTo":null, "function":"approver", "repositoryId":"200001" } ], "dunsNumber":"213456178", "derivedShippingAddressType":"Address2", "derivedDunsNumber":"213456178", "derivedTaxReferenceNumber":"901-70-7000", "contract":{ "endDate":null, "terms":{ "terms":"

Terms and Conditions for contract with National Discount Auto Parts organization

", "repositoryId":"ct-100001" }, "catalog":{ "displayName":"QA Movie and Games Catalog", "repositoryId":"cloudLakeCatalog" }, "displayName":"Contract_NDAP", "repositoryId":"ct-100001", "description":"Contract with National Discount Auto Parts", "priceListGroup":{ "displayName":"Default Price Group", "repositoryId":"defaultPriceGroup" }, "creationDate":"2016-05-04T02:41:00.000Z", "externalContractReference":"Test", "startDate":null }, "derivedCustomerType":"Standard", "active":true, "derivedOrganizationLogo":null, "vatReferenceNumber":null, "orderPriceLimit":50, "derivedShippingAddress":{ "country":"US", "phoneNumber":"631-748-6479", "address2":"Suffolk", "city":"Bohemia", "address1":"70 Euclid Ave #722", "companyName":"National Discount Auto Parts", "postalCode":"11716", "repositoryId":"ci-110024", "state":"NY" }, "derivedType":"company", "approvalRequired":true, "derivedVatReferenceNumber":null, "name":"National Discount Auto Parts", "shippingAddress":{ "country":"US", "phoneNumber":"631-748-6479", "address2":"Suffolk", "city":"Bohemia", "address1":"70 Euclid Ave #722", "companyName":"National Discount Auto Parts", "postalCode":"11716", "repositoryId":"ci-110024", "state":"NY" }, "billingAddress":{ "country":"US", "phoneNumber":"631-748-6479", "address2":"Suffolk", "city":"Bohemia", "address1":"70 Euclid Ave #722", "companyName":"National Discount Auto Parts", "postalCode":"11716", "repositoryId":"ci-110024", "state":"NY" }, "derivedDescription":null, "uniqueId":null }
Default Response
The error response. The following are the internal error codes thrown by this API when the request processing fails in Oracle Commerce Cloud: |Error Code|Description| |------------------|------------------| |22010|If the profile id passed is not associated to the account of the profileId passed in the AgentContext header.| |100000|If input passed is invalid| |100001|If there was no organization found with the given id| |89103|If the shopperProfile passed in the AgentContext header or the associated account is inactive| |100000|If input passed is invalid| |100001|If there was no organization found with the given id|
Body
Root Schema : errorModel
Type: object
Nested Schema : errors
Type: array
An optional list of errors if multiple errors were encountered
Nested Schema : items
Type: object