{"_id":"59a45d2cd12e81000f842f24","category":{"_id":"59a45d2bd12e81000f842eeb","version":"59a45d2bd12e81000f842ee2","project":"57336fd5a6a9c40e00e13a0b","__v":0,"sync":{"url":"","isSync":false},"reference":false,"createdAt":"2016-11-23T19:23:42.327Z","from_sync":false,"order":8,"slug":"marketplace","title":"Marketplace"},"user":"560d5913af97231900938124","parentDoc":null,"project":"57336fd5a6a9c40e00e13a0b","version":{"_id":"59a45d2bd12e81000f842ee2","project":"57336fd5a6a9c40e00e13a0b","__v":1,"createdAt":"2017-08-28T18:12:59.168Z","releaseDate":"2017-08-28T18:12:59.168Z","categories":["59a45d2bd12e81000f842ee3","59a45d2bd12e81000f842ee4","59a45d2bd12e81000f842ee5","59a45d2bd12e81000f842ee6","59a45d2bd12e81000f842ee7","59a45d2bd12e81000f842ee8","59a45d2bd12e81000f842ee9","59a45d2bd12e81000f842eea","59a45d2bd12e81000f842eeb","59a45d2bd12e81000f842eec","59a45d2bd12e81000f842eed","59a45d2bd12e81000f842eee","59a45d2bd12e81000f842eef","59a45d2bd12e81000f842ef0","59a45d2bd12e81000f842ef1"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":false,"codename":"3.22.1","version_clean":"8976.0.0-JSON","version":"8976-JSON"},"__v":1,"updates":[],"next":{"pages":[],"description":""},"createdAt":"2016-11-23T19:24:54.784Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"method":"put","results":{"codes":[]},"settings":"57ee593a21ceb20e0061959e","examples":{"codes":[]},"auth":"optional","params":[{"_id":"586e755ec951871b00a5bc3d","ref":"","in":"path","required":true,"desc":"BlueSnap identifier for the vendor","default":"","type":"int","name":"vendorId"}],"url":"/vendors/:vendorId"},"isReference":false,"order":30,"body":"The Update Vendor request enables you to change any of the following settings for an existing vendor:\n* Vendor address\n* Vendor email\n* Vendor first and last name\n* Vendor business name\n* Vendor phone\n* Vendor frequency and delay\n* Vendor principal\n* Vendor agreement\n* Vendor payout information\n\n**Note**: Modifying certain vendor properties may result in vendor payout suspension. Click [here](/v1.0/docs/updating-vendor-accounts#section-updating-vendor-properties-and-changes-to-payout-status) to learn more. \n[block:callout]\n{\n  \"type\": \"info\",\n  \"title\": \"Important\",\n  \"body\": \"* It is suggested that you first retrieve the vendor and then modify the desired property.\\n\\n* To be eligible for payout, make sure all necessary vendor information has been submitted to BlueSnap. To see the payout requirements, click [here](/docs/vendor-verification-requirements#section-requirements-for-payout).\"\n}\n[/block]\n###Request Content\n`vendor` *object* &nbsp;&nbsp;&nbsp;<span style=\"color:#F37500\">**required**</span>, contains the following properties (see [vendor](doc:vendorinfo)) :\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`email` *string* &nbsp;&nbsp;&nbsp;<span style=\"color:#F37500\">**required**</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`name` *string* &nbsp;&nbsp;&nbsp; optional\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`firstName` *string* &nbsp;&nbsp;&nbsp; optional\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`lastName` *string* &nbsp;&nbsp;&nbsp; optional\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`phone` *string* &nbsp;&nbsp;&nbsp; optional\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`address` *string* &nbsp;&nbsp;&nbsp; optional\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`city` *string* &nbsp;&nbsp;optional\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`country` *string* &nbsp;&nbsp;<span style=\"color:#F37500\">**required**</span>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`state` *string* &nbsp;&nbsp;<span style=\"color:#F37500\">**required**</span> if `payoutInfo` included and country = US or CA. (See [State and Province Codes](http://developers.bluesnap.com/docs/state-and-province-codes)). \n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`zip` *string* &nbsp;&nbsp; optional\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`taxId` *string* &nbsp;&nbsp;&nbsp;optional \n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`vatId` *string* &nbsp;&nbsp;&nbsp;optional\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`defaultPayoutCurrency` *string* &nbsp;&nbsp;&nbsp;optional &nbsp;&nbsp;&nbsp; \n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`frequency` *string* &nbsp;&nbsp;&nbsp;optional &nbsp;&nbsp;&nbsp;\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`delay` *integer* &nbsp;&nbsp;&nbsp;optional &nbsp;&nbsp;&nbsp;\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`vendorPrincipal` *container* &nbsp;&nbsp;&nbsp; optional; (see [vendorPrincipal](doc:vendorprincipal))\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`vendorAgreement` *container* &nbsp;&nbsp;&nbsp; optional; (see [vendorAgreement](doc:vendoragreement))\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`payoutInfo` *container* &nbsp;&nbsp;&nbsp; optional; (see [payoutInfo](doc:payoutinfo))\n\n###Response Details\nIf successful, the response HTTP status code is 204 No Content\n\n<hr>\n\n##Examples\n\n###Request Examples\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"curl -v -X PUT https://sandbox.bluesnap.com/services/2/vendors/514147 \\\\\\n-H 'Content-Type: application/json' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n{\\n    \\\"email\\\": \\\"vendor:::at:::bluesnap.com\\\",\\n    \\\"name\\\": \\\"Important Vendor\\\",\\n    \\\"firstName\\\": \\\"Joe\\\",\\n    \\\"lastName\\\": \\\"Smith\\\",\\n    \\\"address\\\": \\\"123 Main Street\\\",\\n    \\\"city\\\": \\\"testing city\\\",\\n    \\\"zip\\\": \\\"4640802\\\",\\n    \\\"country\\\": \\\"US\\\",\\n    \\\"phone\\\": \\\"1-054-976-6778\\\",\\n    \\\"state\\\": \\\"MA\\\",\\n    \\\"taxId\\\": 123456789,\\n    \\\"defaultPayoutCurrency\\\": \\\"USD\\\", \\n    \\\"vendorPrincipal\\\": {\\n        \\\"firstName\\\": \\\"Joe\\\",\\n        \\\"lastName\\\": \\\"Smith\\\",\\n        \\\"address\\\": \\\"123 Main Street\\\",\\n        \\\"city\\\": \\\"Juneau\\\",\\n        \\\"zip\\\": \\\"12345\\\",\\n        \\\"country\\\": \\\"US\\\",\\n        \\\"dob\\\": \\\"28-09-9999\\\",\\n        \\\"personalIdentificationNumber\\\": 1234,\\n      \\t\\\"driverLicenseNumber\\\": \\\"561196411\\\",\\n        \\\"email\\\": \\\"principal.name@vendor.com\\\"\\n    },\\n    \\\"payoutInfo\\\": [\\n        {\\n            \\\"payoutType\\\": \\\"ACH\\\",\\n            \\\"baseCurrency\\\": \\\"USD\\\",\\n            \\\"nameOnAccount\\\": \\\"vendor\\\",\\n            \\\"bankAccountClass\\\": \\\"PERSONAL\\\",\\n            \\\"bankAccountType\\\": \\\"CHECKING\\\",\\n            \\\"bankName\\\": \\\"Leumi\\\",\\n            \\\"bankId\\\": \\\"12445\\\",\\n            \\\"country\\\": \\\"US\\\",\\n            \\\"city\\\": \\\"Portland\\\",\\n            \\\"address\\\": \\\"1 bank address\\\",\\n            \\\"state\\\": \\\"MA\\\",\\n            \\\"zip\\\": \\\"12345\\\",\\n            \\\"bankAccountId\\\": \\\"36628822\\\"\\n        }\\n    ],\\n    \\\"vendorAgreement\\\": {\\n        \\\"commissionPercent\\\": 20,\\n        \\\"accountStatus\\\": \\\"ACTIVE\\\"\\n    }\\n}'\",\n      \"language\": \"curl\",\n      \"name\": \"Update Vendor: with commission percent\"\n    },\n    {\n      \"code\": \"curl -v -X PUT https://sandbox.bluesnap.com/services/2/vendors/514147 \\\\\\n-H 'Content-Type: application/json' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n{\\n    \\\"email\\\": \\\"vendor@bluesnap.com\\\",\\n    \\\"name\\\": \\\"Important Vendor\\\",\\n    \\\"firstName\\\": \\\"Joe\\\",\\n    \\\"lastName\\\": \\\"Smith\\\",\\n    \\\"address\\\": \\\"123 Main Street\\\",\\n    \\\"city\\\": \\\"testing city\\\",\\n    \\\"zip\\\": \\\"4640802\\\",\\n    \\\"country\\\": \\\"US\\\",\\n    \\\"phone\\\": \\\"1-054-976-6778\\\",\\n    \\\"state\\\": \\\"MA\\\",\\n    \\\"taxId\\\": 123456789,\\n    \\\"defaultPayoutCurrency\\\": \\\"USD\\\", \\n    \\\"vendorPrincipal\\\": {\\n        \\\"firstName\\\": \\\"Joe\\\",\\n        \\\"lastName\\\": \\\"Smith\\\",\\n        \\\"address\\\": \\\"123 Main Street\\\",\\n        \\\"city\\\": \\\"Juneau\\\",\\n        \\\"zip\\\": \\\"12345\\\",\\n        \\\"country\\\": \\\"US\\\",\\n        \\\"dob\\\": \\\"28-09-9999\\\",\\n        \\\"personalIdentificationNumber\\\": 1234,\\n      \\t\\\"driverLicenseNumber\\\": \\\"561196411\\\",\\n        \\\"email\\\": \\\"principal.name@vendor.com\\\"\\n    },\\n    \\\"payoutInfo\\\": [\\n        {\\n            \\\"payoutType\\\": \\\"ACH\\\",\\n            \\\"baseCurrency\\\": \\\"USD\\\",\\n            \\\"nameOnAccount\\\": \\\"vendor\\\",\\n            \\\"bankAccountClass\\\": \\\"PERSONAL\\\",\\n            \\\"bankAccountType\\\": \\\"CHECKING\\\",\\n            \\\"bankName\\\": \\\"Leumi\\\",\\n            \\\"bankId\\\": \\\"12445\\\",\\n            \\\"country\\\": \\\"US\\\",\\n            \\\"city\\\": \\\"Portland\\\",\\n            \\\"address\\\": \\\"1 bank address\\\",\\n            \\\"state\\\": \\\"MA\\\",\\n            \\\"zip\\\": \\\"12345\\\",\\n            \\\"bankAccountId\\\": \\\"36628822\\\"\\n        }\\n    ],\\n    \\\"vendorAgreement\\\": {\\n        \\\"commissionPercent\\\": 20,\\n        \\\"accountStatus\\\": \\\"INACTIVE\\\",\\n        \\\"recurringCommission\\\": \\\"Y\\\"\\n    }\\n}'\",\n      \"language\": \"curl\",\n      \"name\": \"with account status \"\n    },\n    {\n      \"code\": \"curl -v -X PUT https://sandbox.bluesnap.com/services/2/vendors/534231 \\\\\\n-H 'Content-Type: application/json' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n{\\n    \\\"email\\\": \\\"vendor@example.com\\\",\\n    \\\"name\\\": \\\"Business ABC\\\",\\n    \\\"address\\\": \\\"25 Business Avenue\\\",\\n    \\\"city\\\": \\\"Boston\\\",\\n    \\\"zip\\\": \\\"123456\\\",\\n    \\\"country\\\": \\\"US\\\",\\n    \\\"phone\\\": \\\"555-555-5555\\\",\\n    \\\"state\\\": \\\"MA\\\",\\n    \\\"taxId\\\": 123456789,\\n    \\\"defaultPayoutCurrency\\\": \\\"USD\\\", \\n    \\\"vendorPrincipal\\\": {\\n        \\\"firstName\\\": \\\"Joe\\\",\\n        \\\"lastName\\\": \\\"Smith\\\",\\n        \\\"address\\\": \\\"123 Main Street\\\",\\n        \\\"city\\\": \\\"Boston\\\",\\n        \\\"zip\\\": \\\"12345\\\",\\n        \\\"country\\\": \\\"US\\\",\\n        \\\"dob\\\": \\\"28-09-9999\\\",\\n        \\\"personalIdentificationNumber\\\": \\\"1234\\\",\\n        \\\"driverLicenseNumber\\\": \\\"7676234872\\\",\\n        \\\"email\\\": \\\"principal.vendor@example.com\\\"\\n    },\\n    \\\"payoutInfo\\\": [\\n        {\\n            \\\"payoutType\\\": \\\"ACH\\\",\\n            \\\"baseCurrency\\\": \\\"USD\\\",\\n            \\\"minimalPayoutAmount\\\": \\\"50\\\",\\n            \\\"nameOnAccount\\\": \\\"name of vendor account\\\",\\n            \\\"bankAccountClass\\\": \\\"CORPORATE\\\",\\n            \\\"bankAccountType\\\": \\\"CHECKING\\\",\\n            \\\"bankName\\\": \\\"Bank of America\\\",\\n            \\\"bankId\\\": \\\"12445\\\",\\n            \\\"country\\\": \\\"US\\\",\\n            \\\"city\\\": \\\"Boston\\\",\\n            \\\"address\\\": \\\"1 bank address\\\",\\n            \\\"state\\\": \\\"MA\\\",\\n            \\\"zip\\\": \\\"12345\\\",\\n            \\\"bankAccountId\\\": \\\"36628822\\\"\\n        }\\n    ],\\n    \\\"vendorAgreement\\\": {\\n        \\\"commissionPercent\\\": 30\\n    }\\n}'\",\n      \"language\": \"curl\",\n      \"name\": \"simulate vendor decline\"\n    }\n  ]\n}\n[/block]\n#Response Example \n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"HTTP/ 1.1 204 No Content\",\n      \"language\": \"json\",\n      \"name\": \"Update Vendor Response: 204 No Content\"\n    }\n  ]\n}\n[/block]\n##Example Descriptions\n\n###Update Vendor with commission percent\nThis example shows an Update Vendor request where commission percent has been modified by including `commissionPercent` in `vendorAgreement`. For all future transactions, the transaction will be split according to the defined commission rate (unless overridden for a specific transaction). \n\n###Update Vendor with account status   \nThis example shows an Update Vendor request where account status has been switched to **Inactive** by including `accountStatus` with a value of **INACTIVE** within `vendorAgreement`.\n\n###Update Vendor: Simulate a vendor decline\nThis example shows how to simulate a vendor decline in sandbox: Send a Create or Update Vendor request for a vendor and set the value of `phone` to **555-555-5555**. To see the result, send a [Retrieve Vendor](doc:retrieve-vendor) request - you'll notice that `payoutStatus` has a value of **Declined**.","excerpt":"","slug":"update-vendor","type":"put","title":"Update Vendor"}

Definition

{{ api_url }}{{ page_api_url }}

Parameters

Path Params

vendorId:
required
integer
BlueSnap identifier for the vendor

Documentation

The Update Vendor request enables you to change any of the following settings for an existing vendor:

  • Vendor address
  • Vendor email
  • Vendor first and last name
  • Vendor business name
  • Vendor phone
  • Vendor frequency and delay
  • Vendor principal
  • Vendor agreement
  • Vendor payout information

Note: Modifying certain vendor properties may result in vendor payout suspension. Click here to learn more.

Important

  • It is suggested that you first retrieve the vendor and then modify the desired property.

  • To be eligible for payout, make sure all necessary vendor information has been submitted to BlueSnap. To see the payout requirements, click here.

Request Content

vendor object    required, contains the following properties (see vendor) :
      email string    required      
      name string     optional
      firstName string     optional
      lastName string     optional
      phone string     optional
      address string     optional
      city string   optional
      country string   required
      state string   required if payoutInfo included and country = US or CA. (See State and Province Codes).
      zip string    optional
      taxId string    optional
      vatId string    optional
      defaultPayoutCurrency string    optional    
      frequency string    optional    
      delay integer    optional    
      vendorPrincipal container     optional; (see vendorPrincipal)
      vendorAgreement container     optional; (see vendorAgreement)
      payoutInfo container     optional; (see payoutInfo)

Response Details

If successful, the response HTTP status code is 204 No Content


Examples

Request Examples

curl -v -X PUT https://sandbox.bluesnap.com/services/2/vendors/514147 \
-H 'Content-Type: application/json' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
{
    "email": "vendor@bluesnap.com",
    "name": "Important Vendor",
    "firstName": "Joe",
    "lastName": "Smith",
    "address": "123 Main Street",
    "city": "testing city",
    "zip": "4640802",
    "country": "US",
    "phone": "1-054-976-6778",
    "state": "MA",
    "taxId": 123456789,
    "defaultPayoutCurrency": "USD", 
    "vendorPrincipal": {
        "firstName": "Joe",
        "lastName": "Smith",
        "address": "123 Main Street",
        "city": "Juneau",
        "zip": "12345",
        "country": "US",
        "dob": "28-09-9999",
        "personalIdentificationNumber": 1234,
      	"driverLicenseNumber": "561196411",
        "email": "principal.name@vendor.com"
    },
    "payoutInfo": [
        {
            "payoutType": "ACH",
            "baseCurrency": "USD",
            "nameOnAccount": "vendor",
            "bankAccountClass": "PERSONAL",
            "bankAccountType": "CHECKING",
            "bankName": "Leumi",
            "bankId": "12445",
            "country": "US",
            "city": "Portland",
            "address": "1 bank address",
            "state": "MA",
            "zip": "12345",
            "bankAccountId": "36628822"
        }
    ],
    "vendorAgreement": {
        "commissionPercent": 20,
        "accountStatus": "ACTIVE"
    }
}'
curl -v -X PUT https://sandbox.bluesnap.com/services/2/vendors/514147 \
-H 'Content-Type: application/json' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
{
    "email": "vendor@bluesnap.com",
    "name": "Important Vendor",
    "firstName": "Joe",
    "lastName": "Smith",
    "address": "123 Main Street",
    "city": "testing city",
    "zip": "4640802",
    "country": "US",
    "phone": "1-054-976-6778",
    "state": "MA",
    "taxId": 123456789,
    "defaultPayoutCurrency": "USD", 
    "vendorPrincipal": {
        "firstName": "Joe",
        "lastName": "Smith",
        "address": "123 Main Street",
        "city": "Juneau",
        "zip": "12345",
        "country": "US",
        "dob": "28-09-9999",
        "personalIdentificationNumber": 1234,
      	"driverLicenseNumber": "561196411",
        "email": "principal.name@vendor.com"
    },
    "payoutInfo": [
        {
            "payoutType": "ACH",
            "baseCurrency": "USD",
            "nameOnAccount": "vendor",
            "bankAccountClass": "PERSONAL",
            "bankAccountType": "CHECKING",
            "bankName": "Leumi",
            "bankId": "12445",
            "country": "US",
            "city": "Portland",
            "address": "1 bank address",
            "state": "MA",
            "zip": "12345",
            "bankAccountId": "36628822"
        }
    ],
    "vendorAgreement": {
        "commissionPercent": 20,
        "accountStatus": "INACTIVE",
        "recurringCommission": "Y"
    }
}'
curl -v -X PUT https://sandbox.bluesnap.com/services/2/vendors/534231 \
-H 'Content-Type: application/json' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
{
    "email": "vendor@example.com",
    "name": "Business ABC",
    "address": "25 Business Avenue",
    "city": "Boston",
    "zip": "123456",
    "country": "US",
    "phone": "555-555-5555",
    "state": "MA",
    "taxId": 123456789,
    "defaultPayoutCurrency": "USD", 
    "vendorPrincipal": {
        "firstName": "Joe",
        "lastName": "Smith",
        "address": "123 Main Street",
        "city": "Boston",
        "zip": "12345",
        "country": "US",
        "dob": "28-09-9999",
        "personalIdentificationNumber": "1234",
        "driverLicenseNumber": "7676234872",
        "email": "principal.vendor@example.com"
    },
    "payoutInfo": [
        {
            "payoutType": "ACH",
            "baseCurrency": "USD",
            "minimalPayoutAmount": "50",
            "nameOnAccount": "name of vendor account",
            "bankAccountClass": "CORPORATE",
            "bankAccountType": "CHECKING",
            "bankName": "Bank of America",
            "bankId": "12445",
            "country": "US",
            "city": "Boston",
            "address": "1 bank address",
            "state": "MA",
            "zip": "12345",
            "bankAccountId": "36628822"
        }
    ],
    "vendorAgreement": {
        "commissionPercent": 30
    }
}'

Response Example

HTTP/ 1.1 204 No Content

Example Descriptions

Update Vendor with commission percent

This example shows an Update Vendor request where commission percent has been modified by including commissionPercent in vendorAgreement. For all future transactions, the transaction will be split according to the defined commission rate (unless overridden for a specific transaction).

Update Vendor with account status

This example shows an Update Vendor request where account status has been switched to Inactive by including accountStatus with a value of INACTIVE within vendorAgreement.

Update Vendor: Simulate a vendor decline

This example shows how to simulate a vendor decline in sandbox: Send a Create or Update Vendor request for a vendor and set the value of phone to 555-555-5555. To see the result, send a Retrieve Vendor request - you'll notice that payoutStatus has a value of Declined.


User Information

Try It Out


put
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}