FORMAT: 1A
HOST: http://apiblueprint.vapi.devorch.com/

# Group Vectorapi
Group of all vectorapi-related resources.

## Customercurrency

Customer currency resource is deal with DMS related currencies. User may assign currencies to a particular pricing scheme. But this is the resource which would allow user to come up with currencies at DMS level. 

In simple term, user is allow to have a bunch of territories with respect to their currencies for a particular DMS (i.e store). Here we can have different combinations of country and its currency assigned to DMS.

## Get [/vectorapi/customercurrency/get{?id,access_token}]

### Get [GET]

+ Parameters

    + id (number, `150`) ... An unique identifier of the message.
    + access_token (varchar, `some token`)

+ Request JSON Message
    
    + Headers

            Accept: application/json

+ Response 200 (application/json)

    + Body
{
  "envelope": {
    "header": {
      "apiVersion": "1.0",
      "baseUrl": "vapi.alpha.devorch.com",
      "httpStatusCode": 200
    },
    "request": "customercurrency/get?params=vectorapi&customercurrency&get&json&150&<some_token>",
    "response": {
      "customerCurrency": {
        "id": 150,
        "currencyCode": "XCD",
        "country": {
          "__isInitialized__": true,
          "id": 150,
          "name": "Saint Vincent and the Grenadines",
          "abbrivation": "VC",
          "continent": "North America",
          "latitude": null,
          "longitude": null,
          "iso3166a3": "VCT",
          "CountryLanguage": {},
          "CountryRatingAdvisorySystem": {}
        },
        "customerMasterMaster": {
          "__isInitialized__": true,
          "customerMasterMasterId": 1,
          "customerName": "iTunes",
          "sonyDmsCode": "APO",
          "ciDmsCode": "ITM",
          "deliveryOption": "full",
          "showDeliveryInfo": "Y",
          "productTypeId": "1,2,3",
          "deliveryCap": null,
          "weeklyLimit": 5000,
          "eoLimit": 1000,
          "encodingOrderStatus": "close",
          "mvDeliveryOption": "full",
          "CustomerMasterMasterDistributionType": {},
          "ddexPartyId": null,
          "optinDate": "2013-01-01",
          "requiredGenreCode": "Y",
          "requiredSubgenreCode": "N",
          "requiredSubgenre": "N"
        }
      }
    }
  }
}


## Index [/vectorapi/customercurrency/index{?customerMasterMasterId,limit,access_token}]

### Index [GET]

+ Parameters

    + customerMasterMasterId (required, number, `1`)
    + limit (optional, number, `10`)
    + access_token (required, varchar, `some token`)

+ Request JSON Message
    
    + Headers

            Accept: application/json

+ Response 200 (application/json)

    + Body
{
  "envelope": {
    "header": {
      "apiVersion": "1.0",
      "baseUrl": "vapi.alpha.devorch.com",
      "httpStatusCode": 200
    },
    "request": "customercurrency/index?params=vectorapi&customercurrency&index&json&1&10&<some_token>",
    "response": {
      "customerCurrency": [
        {
          "id": 4,
          "currencyCode": "EUR",
          "customerMasterMaster": {
            "customerMasterMasterId": 1,
            "customerName": "iTunes",
            "sonyDmsCode": "APO",
            "productTypeId": "1,2,3"
          },
          "country": {
            "id": 4,
            "name": "Germany",
            "abbrivation": "DE",
            "continent": "Europe"
          }
        },
        {
          "id": 5,
          "currencyCode": "SEK",
          "customerMasterMaster": {
            "customerMasterMasterId": 1,
            "customerName": "iTunes",
            "sonyDmsCode": "APO",
            "productTypeId": "1,2,3"
          },
          "country": {
            "id": 5,
            "name": "Sweden",
            "abbrivation": "SE",
            "continent": "Europe"
          }
        },
        {
          "id": 6,
          "currencyCode": "FRF",
          "customerMasterMaster": {
            "customerMasterMasterId": 1,
            "customerName": "iTunes",
            "sonyDmsCode": "APO",
            "productTypeId": "1,2,3"
          },
          "country": {
            "id": 6,
            "name": "France",
            "abbrivation": "FR",
            "continent": "Europe"
          }
        },
        {
          "id": 7,
          "currencyCode": "MXP",
          "customerMasterMaster": {
            "customerMasterMasterId": 1,
            "customerName": "iTunes",
            "sonyDmsCode": "APO",
            "productTypeId": "1,2,3"
          },
          "country": {
            "id": 7,
            "name": "Mexico",
            "abbrivation": "MX",
            "continent": "North America"
          }
        },
        {
          "id": 8,
          "currencyCode": "AUD",
          "customerMasterMaster": {
            "customerMasterMasterId": 1,
            "customerName": "iTunes",
            "sonyDmsCode": "APO",
            "productTypeId": "1,2,3"
          },
          "country": {
            "id": 8,
            "name": "Australia",
            "abbrivation": "AU",
            "continent": "Oceania"
          }
        },
        {
          "id": 9,
          "currencyCode": "JPY",
          "customerMasterMaster": {
            "customerMasterMasterId": 1,
            "customerName": "iTunes",
            "sonyDmsCode": "APO",
            "productTypeId": "1,2,3"
          },
          "country": {
            "id": 9,
            "name": "Japan",
            "abbrivation": "JP",
            "continent": "Asia"
          }
        },
        {
          "id": 10,
          "currencyCode": "ILS",
          "customerMasterMaster": {
            "customerMasterMasterId": 1,
            "customerName": "iTunes",
            "sonyDmsCode": "APO",
            "productTypeId": "1,2,3"
          },
          "country": {
            "id": 10,
            "name": "Israel",
            "abbrivation": "IL",
            "continent": "Europe"
          }
        },
        {
          "id": 11,
          "currencyCode": "CHF",
          "customerMasterMaster": {
            "customerMasterMasterId": 1,
            "customerName": "iTunes",
            "sonyDmsCode": "APO",
            "productTypeId": "1,2,3"
          },
          "country": {
            "id": 11,
            "name": "Switzerland",
            "abbrivation": "CH",
            "continent": "Europe"
          }
        },
        {
          "id": 12,
          "currencyCode": "EUR",
          "customerMasterMaster": {
            "customerMasterMasterId": 1,
            "customerName": "iTunes",
            "sonyDmsCode": "APO",
            "productTypeId": "1,2,3"
          },
          "country": {
            "id": 12,
            "name": "Italy",
            "abbrivation": "IT",
            "continent": "Europe"
          }
        },
        {
          "id": 14,
          "currencyCode": "EUR",
          "customerMasterMaster": {
            "customerMasterMasterId": 1,
            "customerName": "iTunes",
            "sonyDmsCode": "APO",
            "productTypeId": "1,2,3"
          },
          "country": {
            "id": 14,
            "name": "Greece",
            "abbrivation": "GR",
            "continent": "Europe"
          }
        }
      ]
    }
  }
}

+ **Other Optional Parameters**

    + Optional Parameters : limit, offset, pageNumber, totalRecords
    + Sort Options : columnName, orderBy   

## Post [/vectorapi/customercurrency/post{?data,access_token}]

### Post [POST]

+ Parameters

    + data (varchar, `{"customerMasterMasterId":10,"currencyCode": "USD","countryIds":[11,12,13]}`)
    + access_token (varchar, `some token`)

+ Request JSON Message
    
    + Headers

            Accept: application/json

+ Response 200 (application/json)

    + Body
{
  "envelope": {
    "header": {
      "apiVersion": "1.0",
      "baseUrl": "vapi.alpha.devorch.com",
      "httpStatusCode": 200
    },
    "request": "customercurrency/post?params=vectorapi&customercurrency&post&json&{\"customerMasterMasterId\":10,\"currencyCode\": \"USD\",\"countryIds\":[11,12,14]}&<some_token>",
    "response": {
      "customerCurrency": "success"
    }
  }
}

+ **Required Parameters**

    + Required Parameters : customerMasterMasterId,currencyCode,countryIds


## Put [/vectorapi/customercurrency/put{?data,access_token}]

### Put [POST]

+ Parameters
    
    + data (varchar, `{"id":528,"customerMasterMasterId":10,"currencyCode": "USD","countryId":15}`)    
    + access_token (optional, varchar, `some token`)

+ Request JSON Message
    
    + Headers

            Accept: application/json

+ Response 200 (application/json)

    + Body
{
  "envelope": {
    "header": {
      "apiVersion": "1.0",
      "baseUrl": "vapi.alpha.devorch.com",
      "httpStatusCode": 200
    },
    "request": "customercurrency/put?params=vectorapi&customercurrency&put&json&{\"id\":528,\"customerMasterMasterId\":10,\"currencyCode\": \"USD\",\"countryId\":15}&<some_token>",
    "response": {
      "customerCurrency": {
        "id": 528,
        "currencyCode": "USD",
        "country": {
          "id": 15,
          "name": "Spain",
          "abbrivation": "ES",
          "continent": "Europe",
          "latitude": "40.463667",
          "longitude": "-3.749220",
          "iso3166a3": "ESP",
          "CountryLanguage": {},
          "CountryRatingAdvisorySystem": {}
        },
        "customerMasterMaster": {
          "__isInitialized__": true,
          "customerMasterMasterId": 10,
          "customerName": "Ruckus",
          "sonyDmsCode": "RKO",
          "ciDmsCode": "RUK",
          "deliveryOption": "full",
          "showDeliveryInfo": "Y",
          "productTypeId": "1",
          "deliveryCap": null,
          "weeklyLimit": null,
          "eoLimit": null,
          "encodingOrderStatus": "open",
          "mvDeliveryOption": "cherry_pick",
          "CustomerMasterMasterDistributionType": {},
          "ddexPartyId": null,
          "optinDate": "2013-01-01",
          "requiredGenreCode": null,
          "requiredSubgenreCode": null,
          "requiredSubgenre": null
        }
      }
    }
  }
}
+ **Required Parameters**

    + Required Parameters : id

+ **Other Optional Parameters**

    + Optional Parameters : customerMasterMasterId,currencyCode,countryId 

## Delete [/vectorapi/customercurrency/delete{?id,access_token}]

### Delete [DELETE]

+ Parameters

    + id (number, `531`) ... customer currency id -- primary key
    + access_token (varchar, `some token`)

+ Request JSON Message
    
    + Headers

            Accept: application/json

+ Response 200 (application/json)

    + Body
{
  "envelope": {
    "header": {
      "apiVersion": "1.0",
      "baseUrl": "vapi.alpha.devorch.com",
      "httpStatusCode": 200
    },
    "request": "customercurrency/delete?params=vectorapi&customercurrency&delete&json&529&<some_token>",
    "response": {
      "customerCurrency": true
    }
  }
}
