{"_id":"55e61f88d101191900f30d0f","category":{"_id":"55df7dcd437b3f0d004ba204","pages":["55df7ef3a50de10d00062f70","55e0f40126f51b0d009b171c","55e0f57c7d91840d00824934","55e0f605c13a5a0d00880e6b","55e100eed052580d0038c993","55e1013d26f51b0d009b1759","55e101637d91840d0082493c","55e5f5af9416190d00dc3a59","55e6203dd101191900f30d11","55ea2468ba33bc3500b28cd9","55f85c32a3271b0d00498d51","55f8b70fc449610d002daf9f","56092bafa7cc2f0d00d975b2","56092bd58aedf50d0004cff1","563923d13539050d000820f0","563e732531f7580d00511edf","564a83ec4721851900a67614","564ab6274cd0521700523f17","564ab687c58bef0d0062070a","564ab6ee9f35450d00fc767a","564ab75f33fb500d00567ddd","564ab7c34cd0521700523f19","564ab82233fb500d00567ddf","564b5f0755cfbe0d00de3ba5","564b5f7e55cfbe0d00de3ba7","565cf59677f0090d00581807","565e4266f76b8d0d00554185","565f4119de5dc50d00acfe30","5665c0b8d7490819006a4fd6"],"project":"55dd0853d2d97337001800e2","version":"55de36ec9067202b00de0015","__v":29,"sync":{"url":"","isSync":false},"reference":true,"createdAt":"2015-08-27T21:14:53.972Z","from_sync":false,"order":2,"slug":"customers","title":"Customers"},"user":"55dd080d0efd5821000d53b3","version":{"_id":"55de36ec9067202b00de0015","__v":33,"project":"55dd0853d2d97337001800e2","createdAt":"2015-08-26T22:00:12.384Z","releaseDate":"2015-08-26T22:00:12.383Z","categories":["55de36ed9067202b00de0016","55de36ed9067202b00de0017","55de36ed9067202b00de0018","55df7dcd437b3f0d004ba204","55e4e014177b6e0d00333141","55e4e01fe252ac0d00303a99","55e4e05240cda60d003bad67","55e4e070177b6e0d00333142","55e4e0753325e60d007fbee6","55e4e0803325e60d007fbee7","55e4e086177b6e0d00333143","55e4e0a1177b6e0d00333144","55e4e0aa3325e60d007fbee8","55e4e0b140cda60d003bad6b","55e4e0bae252ac0d00303a9d","55e4e0c5177b6e0d00333145","55e4e0ee3325e60d007fbeea","55e4e0fae252ac0d00303a9e","55e4e100177b6e0d00333147","55f85c8ba3271b0d00498d55","56092e1ac5cff70d007d0131","564b64a3ee12850d0095866e","564b64b5791099170071e9ea","565cd0bfd18ae50d007183d8","565f5f5d6bafd40d0030a063","565f790d6bafd40d0030a09f","56611c464851190d003f9f5d","56637d5b7988ab0d00d0522e","56637d687988ab0d00d0522f","567835df6928b40d009dd650","56e59c043c29b117008dae5b","5704013559c5190e000ab646","572be252de40590e00026934","58af1bf6ebd7370f0078ba09","5cdad81d912ece0039e9a939"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"","version_clean":"3.0.0","version":"3.0"},"githubsync":"","project":"55dd0853d2d97337001800e2","parentDoc":null,"__v":33,"updates":[],"next":{"pages":[],"description":""},"createdAt":"2015-09-01T21:58:32.447Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"examples":{"codes":[]},"method":"post","results":{"codes":[{"language":"text","code":""}]},"settings":"5693eae65f1c951900644c21","auth":"required","params":[],"url":"/customers/accounts"},"isReference":true,"order":7,"body":"[block:callout]\n{\n  \"type\": \"success\",\n  \"title\": \"Sensible defaults\",\n  \"body\": \"When creating a new customer PayStand will assume that when certain information is not specified in a given substructure previously supplied information also applies to this substructure and will copy it over as a default. For example, when at the root of customer object and address is specified but no address is specified for the default bank, legal entity or merchant, PayStand will use the root address and copy it over for the bank, legal entity and merchant. Hence you will only need to include such information if it is different than what has already been specified.\\n\\nCurrently this applies to:\\n* address\\n* contact\\n* defaultBank\"\n}\n[/block]\n\n[block:callout]\n{\n  \"type\": \"warning\",\n  \"title\": \"Sensible defaults and the Platform's responsibility to provide accurate information\",\n  \"body\": \"Even though PayStand is making it easier on platforms to create new customers by using sensible defaults, it is still **the platform's responsibility to provide accurate information**. I.e. if the merchant's business address is different from the bank address and different from the legal entity address, it is the platforms responsibility to make sure to provide PayStand with the accurate address information for each of these.\"\n}\n[/block]\n\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Parameter\",\n    \"h-1\": \"Required\",\n    \"0-0\": \"name\",\n    \"0-1\": \"Required\",\n    \"1-0\": \"email\",\n    \"1-1\": \"Optional\",\n    \"3-0\": \"address\",\n    \"3-1\": \"Optional\",\n    \"4-0\": \"contact\",\n    \"4-1\": \"Optional\",\n    \"5-0\": \"planKey\",\n    \"5-1\": \"Required\",\n    \"6-0\": \"settings\",\n    \"6-1\": \"Optional\",\n    \"11-0\": \"meta\",\n    \"11-1\": \"Optional\",\n    \"12-0\": \"legalEntity\",\n    \"12-1\": \"Optional\",\n    \"13-0\": \"merchant\",\n    \"13-1\": \"Optional\",\n    \"7-0\": \"defaultSettings\",\n    \"7-1\": \"Optional\",\n    \"2-0\": \"description\",\n    \"2-1\": \"Optional\",\n    \"8-0\": \"defaultBank\",\n    \"8-1\": \"Required\",\n    \"9-0\": \"username\",\n    \"9-1\": \"Optional\",\n    \"10-0\": \"password\",\n    \"10-1\": \"Optional\"\n  },\n  \"cols\": 2,\n  \"rows\": 14\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"{\\n  \\\"Authorization\\\": \\\"Bearer 8xwEjewopIwfzWp28ai6VnqNJEEr2Gow\\\",\\n  \\\"X-CUSTOMER-ID\\\": \\\"925a77c119c741439592c23d\\\",\\n  \\\"Accept\\\": \\\"application/json\\\",\\n  \\\"Content-Type\\\": \\\"application/json\\\"\\n}\",\n      \"language\": \"json\",\n      \"name\": \"Headers\"\n    }\n  ],\n  \"sidebar\": true\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"{\\n  \\\"name\\\": \\\"Martha's Flowers\\\",\\n  \\\"email\\\": \\\"martha:::at:::marthasflowers-test.com\\\",\\n  \\\"username\\\" : \\\"bigsis\\\",\\n  \\\"password\\\" : \\\"4littlebro\\\",\\n  \\\"address\\\": {\\n    \\\"street1\\\": \\\"123 account st\\\",\\n    \\\"street2\\\": \\\"3g\\\",\\n    \\\"city\\\": \\\"santa cruz\\\",\\n    \\\"state\\\": \\\"CA\\\",\\n    \\\"postalCode\\\": \\\"95060\\\",\\n    \\\"country\\\": \\\"USA\\\"\\n  },\\n  \\\"contact\\\": {\\n    \\\"firstName\\\": \\\"Martha\\\",\\n    \\\"lastName\\\": \\\"Flowers\\\",\\n    \\\"email\\\": \\\"martha@marthasflowers-test.com\\\",\\n    \\\"phone\\\": \\\"8312223333\\\",\\n    \\\"dateOfBirth\\\": \\\"08-30-1984\\\"\\n  },\\n  \\\"meta\\\": {\\n    \\\"clientCustomerId\\\": \\\"2144cccbc048401fa0b12309b2e9c826\\\"\\n  },\\n  \\\"settings\\\": {\\n    \\\"events\\\": {\\n      \\\"enabled\\\": true,\\n      \\\"urls\\\": {\\n        \\\"always\\\": [\\\"http://api.marthasflowers-test.com/webhooks\\\"]\\n      }\\n    }\\n  },\\n  \\\"defaultSettings\\\": {\\n    \\\"events\\\": {\\n      \\\"enabled\\\": true,\\n      \\\"urls\\\": {\\n        \\\"always\\\": [\\\"http://api.platform-company-test.com/webhooks\\\"]\\n      }\\n    }\\n  },\\n  \\\"planKey\\\": \\\"Merchant Pro\\\",\\n  \\\"defaultBank\\\": {\\n    \\\"nameOnAccount\\\": \\\"Martha Flowers\\\",\\n    \\\"accountHolderType\\\": \\\"company\\\",\\n    \\\"accountNumber\\\": \\\"000123456789\\\",\\n    \\\"routingNumber\\\": \\\"110000000\\\",\\n    \\\"accountType\\\": \\\"checking\\\"\\n  },\\n  \\\"legalEntity\\\": {\\n    \\\"entityType\\\": \\\"LLC\\\",\\n    \\\"yearsInBusiness\\\": \\\"5\\\",\\n    \\\"businessName\\\": \\\"Martha's Flowers\\\",\\n    \\\"businessTaxId\\\": \\\"000000000\\\",\\n    \\\"businessSalesVolume\\\": \\\"2000\\\",\\n    \\\"businessAcceptedCards\\\": true,\\n    \\\"personalTaxId\\\": \\\"000000000\\\",\\n    \\\"stakePercent\\\": \\\"70\\\",\\n    \\\"additionalOwners\\\": [\\n      {\\n        \\\"personalTaxId\\\": \\\"123456789\\\",\\n        \\\"stakePercent\\\": \\\"30\\\",\\n        \\\"title\\\": \\\"CFO\\\",\\n        \\\"address\\\": {..},\\n        \\\"contact\\\": {..}\\n      }\\n    ]\\n  },\\n  \\\"merchant\\\": {\\n    \\\"businessName\\\": \\\"Martha's FLowers\\\",\\n    \\\"businessUrl\\\": \\\"http://www.marthasflowers-test.com\\\",\\n    \\\"businessLogo\\\": \\\"http://www.marthasflowers-test.com/images/flowers.jpg\\\",\\n    \\\"supportEmail\\\": \\\"support@marthasflowers-test.com\\\",\\n    \\\"supportPhone\\\": \\\"8317778888\\\",\\n    \\\"supportUrl\\\": \\\"http://www.marthasflowers-test.com\\\",\\n    \\\"productDescription\\\": \\\"We sell flowers\\\",\\n    \\\"statementDescriptor\\\": \\\"Marthas Flowers\\\",\\n    \\\"merchantCategoryCode\\\": \\\"4816\\\"\\n  }\\n}\",\n      \"language\": \"json\",\n      \"name\": \"Request\"\n    }\n  ],\n  \"sidebar\": true\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"{\\n  \\\"account\\\": {\\n    \\\"object\\\": \\\"customer\\\",\\n    \\\"id\\\": \\\"5lhbn6gvlmspmpo0jtkrnbm1\\\",\\n    \\\"name\\\": \\\"Martha's Flowers\\\",\\n    \\\"email\\\": \\\"martha@marthasflowers-test.com\\\",\\n    \\\"vanityName\\\": \\\"marthasflowers-5lhbn6gvlmspmpo0jtkrnbm1\\\",\\n    \\\"meta\\\": {\\n      \\\"clientCustomerId\\\": \\\"2144cccbc048401fa0b12309b2e9c826\\\"\\n    },\\n    \\\"planId\\\": \\\"rscog1koxbx9ppvltkx0fok6\\\",\\n    \\\"planName\\\": \\\"Merchant Pro\\\",\\n    \\\"planStatus\\\": {\\n      \\\"plan\\\": \\\"Merchant Pro\\\",\\n      \\\"status\\\": \\\"incomplete\\\",\\n      \\\"needed\\\": [\\n        \\\"underwritingData\\\"\\n      ],\\n      \\\"verifications\\\": {\\n        \\\"professional\\\": \\\"incomplete\\\"\\n      }\\n    },\\n    \\\"defaultBank\\\": {\\n      \\\"object\\\": \\\"bank\\\",\\n      \\\"id\\\": \\\"qkjssrkv3yvvpsj5z340v4v2\\\",\\n      \\\"accountType\\\": \\\"checking\\\",\\n      \\\"bankName\\\": \\\"PayStand Test Bank\\\",\\n      \\\"routingNumber\\\": \\\"110000000\\\",\\n      \\\"nameOnAccount\\\": \\\"Martha Flowers\\\",\\n      \\\"accountHolderType\\\": \\\"company\\\",\\n      \\\"currency\\\": \\\"USD\\\",\\n      \\\"country\\\": \\\"USA\\\",\\n      \\\"last4\\\": \\\"6789\\\",\\n      \\\"fingerprint\\\": \\\"zefxwr581ahem2ek3vfjehki\\\",\\n      \\\"isDefault\\\": false,\\n      \\\"billingAddress\\\": {\\n        \\\"object\\\": \\\"address\\\",\\n        \\\"id\\\": \\\"mbmjr7yvk6ueq6ryv9f8xk62\\\",\\n        \\\"street1\\\": \\\"123 account st\\\",\\n        \\\"street2\\\": \\\"3g\\\",\\n        \\\"city\\\": \\\"santa cruz\\\",\\n        \\\"state\\\": \\\"CA\\\",\\n        \\\"postalCode\\\": \\\"95060\\\",\\n        \\\"country\\\": \\\"USA\\\",\\n        \\\"status\\\": \\\"created\\\",\\n        \\\"created\\\": \\\"2017-02-21T23:27:25.000Z\\\",\\n        \\\"lastUpdated\\\": \\\"2017-02-21T23:27:25.000Z\\\"\\n      },\\n      \\\"dropped\\\": false,\\n      \\\"verified\\\": false,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"created\\\": \\\"2017-02-21T23:27:25.000Z\\\",\\n      \\\"lastUpdated\\\": \\\"2017-02-21T23:27:26.000Z\\\"\\n    },\\n    \\\"address\\\": {\\n      \\\"object\\\": \\\"address\\\",\\n      \\\"id\\\": \\\"szld4d2vbrmulkmujog7inrx\\\",\\n      \\\"street1\\\": \\\"123 account st\\\",\\n      \\\"street2\\\": \\\"3g\\\",\\n      \\\"city\\\": \\\"santa cruz\\\",\\n      \\\"state\\\": \\\"CA\\\",\\n      \\\"postalCode\\\": \\\"95060\\\",\\n      \\\"country\\\": \\\"USA\\\",\\n      \\\"status\\\": \\\"created\\\",\\n      \\\"created\\\": \\\"2017-02-21T23:27:25.000Z\\\",\\n      \\\"lastUpdated\\\": \\\"2017-02-21T23:27:25.000Z\\\"\\n    },\\n    \\\"contact\\\": {\\n      \\\"object\\\": \\\"contact\\\",\\n      \\\"id\\\": \\\"pr19qgpivbbwk1d8bq6qn88g\\\",\\n      \\\"firstName\\\": \\\"Martha\\\",\\n      \\\"lastName\\\": \\\"Flowers\\\",\\n      \\\"email\\\": \\\"martha@marthasflowers-test.com\\\",\\n      \\\"phone\\\": \\\"8312223333\\\",\\n      \\\"dateOfBirth\\\": \\\"08-30-1984\\\",\\n      \\\"status\\\": \\\"created\\\",\\n      \\\"created\\\": \\\"2017-02-21T23:27:25.000Z\\\",\\n      \\\"lastUpdated\\\": \\\"2017-02-21T23:27:25.000Z\\\"\\n    },\\n    \\\"keys\\\": {\\n      \\\"object\\\": \\\"apiKey\\\",\\n      \\\"id\\\": \\\"5meq0e2dm0jja24875sknry\\\",\\n      \\\"publishable\\\": \\\"q9bf0ikhkhkhjjvr4ht4ojhx\\\",\\n      \\\"secret\\\": \\\"gw6lkjji8776678jegcue6wctn0\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"created\\\": \\\"2017-02-21T23:27:26.000Z\\\",\\n      \\\"lastUpdated\\\": \\\"2017-02-21T23:27:26.000Z\\\"\\n    },\\n    \\\"legalEntity\\\": {\\n      \\\"object\\\": \\\"legalEntity\\\",\\n      \\\"id\\\": \\\"hi8o2pz54axjln41r7egad2s\\\",\\n      \\\"entityType\\\": \\\"LLC\\\",\\n      \\\"businessName\\\": \\\"Martha's Flowers\\\",\\n      \\\"yearsInBusiness\\\": \\\"5\\\",\\n      \\\"last4BusinessTaxId\\\": \\\"0000\\\",\\n      \\\"businessSalesVolume\\\": \\\"2000\\\",\\n      \\\"businessAcceptedCards\\\": true,\\n      \\\"last4PersonalTaxId\\\": \\\"0000\\\",\\n      \\\"stakePercent\\\": \\\"70\\\",\\n      \\\"businessAddress\\\": {\\n        \\\"object\\\": \\\"address\\\",\\n        \\\"id\\\": \\\"6cw1jettfwy8nvgz8bg7s2cv\\\",\\n        \\\"street1\\\": \\\"123 account st\\\",\\n        \\\"street2\\\": \\\"3g\\\",\\n        \\\"city\\\": \\\"santa cruz\\\",\\n        \\\"state\\\": \\\"CA\\\",\\n        \\\"postalCode\\\": \\\"95060\\\",\\n        \\\"country\\\": \\\"USA\\\",\\n        \\\"status\\\": \\\"created\\\",\\n        \\\"created\\\": \\\"2017-02-21T23:27:26.000Z\\\",\\n        \\\"lastUpdated\\\": \\\"2017-02-21T23:27:26.000Z\\\"\\n      },\\n      \\\"personalAddress\\\": {\\n        \\\"object\\\": \\\"address\\\",\\n        \\\"id\\\": \\\"ioer77kgv9vplk0a8n5yh0hr\\\",\\n        \\\"street1\\\": \\\"123 account st\\\",\\n        \\\"street2\\\": \\\"3g\\\",\\n        \\\"city\\\": \\\"santa cruz\\\",\\n        \\\"state\\\": \\\"CA\\\",\\n        \\\"postalCode\\\": \\\"95060\\\",\\n        \\\"country\\\": \\\"USA\\\",\\n        \\\"status\\\": \\\"created\\\",\\n        \\\"created\\\": \\\"2017-02-21T23:27:26.000Z\\\",\\n        \\\"lastUpdated\\\": \\\"2017-02-21T23:27:26.000Z\\\"\\n      },\\n      \\\"personalContact\\\": {\\n        \\\"object\\\": \\\"contact\\\",\\n        \\\"id\\\": \\\"pmqpa2jwvdufjljaq6tty0oy\\\",\\n        \\\"firstName\\\": \\\"Martha\\\",\\n        \\\"lastName\\\": \\\"Flowers\\\",\\n        \\\"email\\\": \\\"martha@marthasflowers-test.com\\\",\\n        \\\"phone\\\": \\\"8312223333\\\",\\n        \\\"dateOfBirth\\\": \\\"08-30-1984\\\",\\n        \\\"status\\\": \\\"created\\\",\\n        \\\"created\\\": \\\"2017-02-21T23:27:26.000Z\\\",\\n        \\\"lastUpdated\\\": \\\"2017-02-21T23:27:26.000Z\\\"\\n      },\\n      \\\"additionalOwners\\\": [\\n        {\\n          \\\"personalTaxId\\\": \\\"123456789\\\",\\n          \\\"stakePercent\\\": \\\"30\\\",\\n          \\\"title\\\": \\\"CFO\\\",\\n          \\\"address\\\": {..},\\n          \\\"contact\\\": {..}\\n        }\\n      ],\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"created\\\": \\\"2017-02-21T23:27:26.000Z\\\",\\n      \\\"lastUpdated\\\": \\\"2017-02-21T23:27:26.000Z\\\"\\n    },\\n    \\\"merchant\\\": {\\n      \\\"object\\\": \\\"merchant\\\",\\n      \\\"id\\\": \\\"wz4oi61p2hstk011ly3b1l01\\\",\\n      \\\"businessName\\\": \\\"Martha's FLowers\\\",\\n      \\\"businessUrl\\\": \\\"http://www.marthasflowers-test.com\\\",\\n      \\\"businessLogo\\\": \\\"http://www.marthasflowers-test.com/images/flowers.jpg\\\",\\n      \\\"supportEmail\\\": \\\"support@marthasflowers-test.com\\\",\\n      \\\"supportPhone\\\": \\\"8317778888\\\",\\n      \\\"supportUrl\\\": \\\"http://www.marthasflowers-test.com\\\",\\n      \\\"productDescription\\\": \\\"We sell flowers\\\",\\n      \\\"statementDescriptor\\\": \\\"Marthas Flowers\\\",\\n      \\\"defaultCurrency\\\": \\\"USD\\\",\\n      \\\"merchantCategoryCode\\\": \\\"12345\\\",\\n      \\\"businessAddress\\\": {\\n        \\\"object\\\": \\\"address\\\",\\n        \\\"id\\\": \\\"a64iiems4494kthtg8m5bqau\\\",\\n        \\\"street1\\\": \\\"123 account st\\\",\\n        \\\"street2\\\": \\\"3g\\\",\\n        \\\"city\\\": \\\"santa cruz\\\",\\n        \\\"state\\\": \\\"CA\\\",\\n        \\\"postalCode\\\": \\\"95060\\\",\\n        \\\"country\\\": \\\"USA\\\",\\n        \\\"status\\\": \\\"created\\\",\\n        \\\"created\\\": \\\"2017-02-21T23:27:25.000Z\\\",\\n        \\\"lastUpdated\\\": \\\"2017-02-21T23:27:25.000Z\\\"\\n      },\\n      \\\"personalContact\\\": {\\n        \\\"object\\\": \\\"contact\\\",\\n        \\\"id\\\": \\\"gnjxsvduqm1qj2a78sfubw88\\\",\\n        \\\"firstName\\\": \\\"Martha\\\",\\n        \\\"lastName\\\": \\\"Flowers\\\",\\n        \\\"email\\\": \\\"martha@marthasflowers-test.com\\\",\\n        \\\"phone\\\": \\\"8312223333\\\",\\n        \\\"dateOfBirth\\\": \\\"08-30-1984\\\",\\n        \\\"status\\\": \\\"created\\\",\\n        \\\"created\\\": \\\"2017-02-21T23:27:25.000Z\\\",\\n        \\\"lastUpdated\\\": \\\"2017-02-21T23:27:25.000Z\\\"\\n      },\\n      \\\"bank\\\": {\\n        \\\"object\\\": \\\"bank\\\",\\n        \\\"id\\\": \\\"qkjssrkv3yvvpsj5z340v4v2\\\",\\n        \\\"accountType\\\": \\\"checking\\\",\\n        \\\"bankName\\\": \\\"PayStand Test Bank\\\",\\n        \\\"routingNumber\\\": \\\"110000000\\\",\\n        \\\"nameOnAccount\\\": \\\"Martha Flowers\\\",\\n        \\\"accountHolderType\\\": \\\"company\\\",\\n        \\\"currency\\\": \\\"USD\\\",\\n        \\\"country\\\": \\\"USA\\\",\\n        \\\"last4\\\": \\\"6789\\\",\\n        \\\"fingerprint\\\": \\\"zefxwr581ahem2ek3vfjehki\\\",\\n        \\\"isDefault\\\": false,\\n        \\\"billingAddress\\\": {\\n          \\\"object\\\": \\\"address\\\",\\n          \\\"id\\\": \\\"mbmjr7yvk6ueq6ryv9f8xk62\\\",\\n          \\\"street1\\\": \\\"123 account st\\\",\\n          \\\"street2\\\": \\\"3g\\\",\\n          \\\"city\\\": \\\"santa cruz\\\",\\n          \\\"state\\\": \\\"CA\\\",\\n          \\\"postalCode\\\": \\\"95060\\\",\\n          \\\"country\\\": \\\"USA\\\",\\n          \\\"status\\\": \\\"created\\\",\\n          \\\"created\\\": \\\"2017-02-21T23:27:25.000Z\\\",\\n          \\\"lastUpdated\\\": \\\"2017-02-21T23:27:25.000Z\\\"\\n        },\\n        \\\"dropped\\\": false,\\n        \\\"verified\\\": false,\\n        \\\"status\\\": \\\"active\\\",\\n        \\\"created\\\": \\\"2017-02-21T23:27:25.000Z\\\",\\n        \\\"lastUpdated\\\": \\\"2017-02-21T23:27:26.000Z\\\"\\n      },\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"created\\\": \\\"2017-02-21T23:27:25.000Z\\\",\\n      \\\"lastUpdated\\\": \\\"2017-02-21T23:27:26.000Z\\\"\\n    },\\n    \\\"settings\\\": {\\n      \\\"object\\\": \\\"settings\\\",\\n      \\\"id\\\": \\\"7krgkg4iuk7pjc3qs9fbbnfe\\\",\\n      \\\"events\\\": {\\n        \\\"enabled\\\": true,\\n        \\\"urls\\\": {\\n          \\\"always\\\": [\\n            \\\"http://api.marthasflowers-test.com/webhooks\\\"\\n          ]\\n        }\\n      },\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"created\\\": \\\"2017-02-21T23:27:26.000Z\\\",\\n      \\\"lastUpdated\\\": \\\"2017-02-21T23:27:26.000Z\\\"\\n    },\\n    \\\"accountSettings\\\": {\\n      \\\"object\\\": \\\"settings\\\",\\n      \\\"id\\\": \\\"t8xswe8znw8zp7fs4o7phw9i\\\",\\n      \\\"events\\\": {\\n        \\\"enabled\\\": true,\\n        \\\"urls\\\": {\\n          \\\"always\\\": [\\n            \\\"http://api.platform-company-test.com/webhooks\\\"\\n          ]\\n        }\\n      },\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"created\\\": \\\"2017-02-21T23:27:26.000Z\\\",\\n      \\\"lastUpdated\\\": \\\"2017-02-21T23:27:26.000Z\\\"\\n    },\\n    \\\"timezone\\\": \\\"UTC\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"ownerId\\\": \\\"5lhbn6gvlmspmpo0jtkrnbm1\\\",\\n    \\\"created\\\": \\\"2017-02-21T23:27:25.000Z\\\",\\n    \\\"lastUpdated\\\": \\\"2017-02-21T23:27:28.871Z\\\"\\n  },\\n  \\\"application\\\": {\\n    \\\"object\\\": \\\"application\\\",\\n    \\\"id\\\": \\\"fca72a0f774a83ca1e3d159980f9abfd\\\",\\n    \\\"name\\\": \\\"Default application\\\",\\n    \\\"scope\\\": \\\"auth\\\",\\n    \\\"tokenType\\\": \\\"bearer\\\",\\n    \\\"grantTypes\\\": [\\n      \\\"authorization_code\\\",\\n      \\\"implicit\\\",\\n      \\\"client_credentials\\\",\\n      \\\"password\\\"\\n    ],\\n    \\\"restApiKey\\\": \\\"73dc00b612222222222220005a0335b7ea82bd957c\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"created\\\": \\\"2017-02-21T23:27:29.000Z\\\",\\n    \\\"lastUpdated\\\": \\\"2017-02-21T23:27:29.000Z\\\",\\n    \\\"client_secret\\\": \\\"73dc00b61cb345234523452345234523452345bd957c\\\",\\n    \\\"client_id\\\": \\\"fca72a0f774a83ca1e3d123452345\\\",\\n    \\\"publishableKey\\\": \\\"fca72a0f774a83ca1e234523452345d\\\"\\n  }\\n}\",\n      \"language\": \"json\",\n      \"name\": \"Response\"\n    }\n  ],\n  \"sidebar\": true\n}\n[/block]","excerpt":"Create a customer","slug":"create-customer","type":"endpoint","title":"Create a customer (recommended method)"}

postCreate a customer (recommended method)

Create a customer

Definition

{{ api_url }}{{ page_api_url }}

Documentation

[block:callout] { "type": "success", "title": "Sensible defaults", "body": "When creating a new customer PayStand will assume that when certain information is not specified in a given substructure previously supplied information also applies to this substructure and will copy it over as a default. For example, when at the root of customer object and address is specified but no address is specified for the default bank, legal entity or merchant, PayStand will use the root address and copy it over for the bank, legal entity and merchant. Hence you will only need to include such information if it is different than what has already been specified.\n\nCurrently this applies to:\n* address\n* contact\n* defaultBank" } [/block] [block:callout] { "type": "warning", "title": "Sensible defaults and the Platform's responsibility to provide accurate information", "body": "Even though PayStand is making it easier on platforms to create new customers by using sensible defaults, it is still **the platform's responsibility to provide accurate information**. I.e. if the merchant's business address is different from the bank address and different from the legal entity address, it is the platforms responsibility to make sure to provide PayStand with the accurate address information for each of these." } [/block] [block:parameters] { "data": { "h-0": "Parameter", "h-1": "Required", "0-0": "name", "0-1": "Required", "1-0": "email", "1-1": "Optional", "3-0": "address", "3-1": "Optional", "4-0": "contact", "4-1": "Optional", "5-0": "planKey", "5-1": "Required", "6-0": "settings", "6-1": "Optional", "11-0": "meta", "11-1": "Optional", "12-0": "legalEntity", "12-1": "Optional", "13-0": "merchant", "13-1": "Optional", "7-0": "defaultSettings", "7-1": "Optional", "2-0": "description", "2-1": "Optional", "8-0": "defaultBank", "8-1": "Required", "9-0": "username", "9-1": "Optional", "10-0": "password", "10-1": "Optional" }, "cols": 2, "rows": 14 } [/block] [block:code] { "codes": [ { "code": "{\n \"Authorization\": \"Bearer 8xwEjewopIwfzWp28ai6VnqNJEEr2Gow\",\n \"X-CUSTOMER-ID\": \"925a77c119c741439592c23d\",\n \"Accept\": \"application/json\",\n \"Content-Type\": \"application/json\"\n}", "language": "json", "name": "Headers" } ], "sidebar": true } [/block] [block:code] { "codes": [ { "code": "{\n \"name\": \"Martha's Flowers\",\n \"email\": \"martha@marthasflowers-test.com\",\n \"username\" : \"bigsis\",\n \"password\" : \"4littlebro\",\n \"address\": {\n \"street1\": \"123 account st\",\n \"street2\": \"3g\",\n \"city\": \"santa cruz\",\n \"state\": \"CA\",\n \"postalCode\": \"95060\",\n \"country\": \"USA\"\n },\n \"contact\": {\n \"firstName\": \"Martha\",\n \"lastName\": \"Flowers\",\n \"email\": \"martha@marthasflowers-test.com\",\n \"phone\": \"8312223333\",\n \"dateOfBirth\": \"08-30-1984\"\n },\n \"meta\": {\n \"clientCustomerId\": \"2144cccbc048401fa0b12309b2e9c826\"\n },\n \"settings\": {\n \"events\": {\n \"enabled\": true,\n \"urls\": {\n \"always\": [\"http://api.marthasflowers-test.com/webhooks\"]\n }\n }\n },\n \"defaultSettings\": {\n \"events\": {\n \"enabled\": true,\n \"urls\": {\n \"always\": [\"http://api.platform-company-test.com/webhooks\"]\n }\n }\n },\n \"planKey\": \"Merchant Pro\",\n \"defaultBank\": {\n \"nameOnAccount\": \"Martha Flowers\",\n \"accountHolderType\": \"company\",\n \"accountNumber\": \"000123456789\",\n \"routingNumber\": \"110000000\",\n \"accountType\": \"checking\"\n },\n \"legalEntity\": {\n \"entityType\": \"LLC\",\n \"yearsInBusiness\": \"5\",\n \"businessName\": \"Martha's Flowers\",\n \"businessTaxId\": \"000000000\",\n \"businessSalesVolume\": \"2000\",\n \"businessAcceptedCards\": true,\n \"personalTaxId\": \"000000000\",\n \"stakePercent\": \"70\",\n \"additionalOwners\": [\n {\n \"personalTaxId\": \"123456789\",\n \"stakePercent\": \"30\",\n \"title\": \"CFO\",\n \"address\": {..},\n \"contact\": {..}\n }\n ]\n },\n \"merchant\": {\n \"businessName\": \"Martha's FLowers\",\n \"businessUrl\": \"http://www.marthasflowers-test.com\",\n \"businessLogo\": \"http://www.marthasflowers-test.com/images/flowers.jpg\",\n \"supportEmail\": \"support@marthasflowers-test.com\",\n \"supportPhone\": \"8317778888\",\n \"supportUrl\": \"http://www.marthasflowers-test.com\",\n \"productDescription\": \"We sell flowers\",\n \"statementDescriptor\": \"Marthas Flowers\",\n \"merchantCategoryCode\": \"4816\"\n }\n}", "language": "json", "name": "Request" } ], "sidebar": true } [/block] [block:code] { "codes": [ { "code": "{\n \"account\": {\n \"object\": \"customer\",\n \"id\": \"5lhbn6gvlmspmpo0jtkrnbm1\",\n \"name\": \"Martha's Flowers\",\n \"email\": \"martha@marthasflowers-test.com\",\n \"vanityName\": \"marthasflowers-5lhbn6gvlmspmpo0jtkrnbm1\",\n \"meta\": {\n \"clientCustomerId\": \"2144cccbc048401fa0b12309b2e9c826\"\n },\n \"planId\": \"rscog1koxbx9ppvltkx0fok6\",\n \"planName\": \"Merchant Pro\",\n \"planStatus\": {\n \"plan\": \"Merchant Pro\",\n \"status\": \"incomplete\",\n \"needed\": [\n \"underwritingData\"\n ],\n \"verifications\": {\n \"professional\": \"incomplete\"\n }\n },\n \"defaultBank\": {\n \"object\": \"bank\",\n \"id\": \"qkjssrkv3yvvpsj5z340v4v2\",\n \"accountType\": \"checking\",\n \"bankName\": \"PayStand Test Bank\",\n \"routingNumber\": \"110000000\",\n \"nameOnAccount\": \"Martha Flowers\",\n \"accountHolderType\": \"company\",\n \"currency\": \"USD\",\n \"country\": \"USA\",\n \"last4\": \"6789\",\n \"fingerprint\": \"zefxwr581ahem2ek3vfjehki\",\n \"isDefault\": false,\n \"billingAddress\": {\n \"object\": \"address\",\n \"id\": \"mbmjr7yvk6ueq6ryv9f8xk62\",\n \"street1\": \"123 account st\",\n \"street2\": \"3g\",\n \"city\": \"santa cruz\",\n \"state\": \"CA\",\n \"postalCode\": \"95060\",\n \"country\": \"USA\",\n \"status\": \"created\",\n \"created\": \"2017-02-21T23:27:25.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:25.000Z\"\n },\n \"dropped\": false,\n \"verified\": false,\n \"status\": \"active\",\n \"created\": \"2017-02-21T23:27:25.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:26.000Z\"\n },\n \"address\": {\n \"object\": \"address\",\n \"id\": \"szld4d2vbrmulkmujog7inrx\",\n \"street1\": \"123 account st\",\n \"street2\": \"3g\",\n \"city\": \"santa cruz\",\n \"state\": \"CA\",\n \"postalCode\": \"95060\",\n \"country\": \"USA\",\n \"status\": \"created\",\n \"created\": \"2017-02-21T23:27:25.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:25.000Z\"\n },\n \"contact\": {\n \"object\": \"contact\",\n \"id\": \"pr19qgpivbbwk1d8bq6qn88g\",\n \"firstName\": \"Martha\",\n \"lastName\": \"Flowers\",\n \"email\": \"martha@marthasflowers-test.com\",\n \"phone\": \"8312223333\",\n \"dateOfBirth\": \"08-30-1984\",\n \"status\": \"created\",\n \"created\": \"2017-02-21T23:27:25.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:25.000Z\"\n },\n \"keys\": {\n \"object\": \"apiKey\",\n \"id\": \"5meq0e2dm0jja24875sknry\",\n \"publishable\": \"q9bf0ikhkhkhjjvr4ht4ojhx\",\n \"secret\": \"gw6lkjji8776678jegcue6wctn0\",\n \"status\": \"active\",\n \"created\": \"2017-02-21T23:27:26.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:26.000Z\"\n },\n \"legalEntity\": {\n \"object\": \"legalEntity\",\n \"id\": \"hi8o2pz54axjln41r7egad2s\",\n \"entityType\": \"LLC\",\n \"businessName\": \"Martha's Flowers\",\n \"yearsInBusiness\": \"5\",\n \"last4BusinessTaxId\": \"0000\",\n \"businessSalesVolume\": \"2000\",\n \"businessAcceptedCards\": true,\n \"last4PersonalTaxId\": \"0000\",\n \"stakePercent\": \"70\",\n \"businessAddress\": {\n \"object\": \"address\",\n \"id\": \"6cw1jettfwy8nvgz8bg7s2cv\",\n \"street1\": \"123 account st\",\n \"street2\": \"3g\",\n \"city\": \"santa cruz\",\n \"state\": \"CA\",\n \"postalCode\": \"95060\",\n \"country\": \"USA\",\n \"status\": \"created\",\n \"created\": \"2017-02-21T23:27:26.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:26.000Z\"\n },\n \"personalAddress\": {\n \"object\": \"address\",\n \"id\": \"ioer77kgv9vplk0a8n5yh0hr\",\n \"street1\": \"123 account st\",\n \"street2\": \"3g\",\n \"city\": \"santa cruz\",\n \"state\": \"CA\",\n \"postalCode\": \"95060\",\n \"country\": \"USA\",\n \"status\": \"created\",\n \"created\": \"2017-02-21T23:27:26.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:26.000Z\"\n },\n \"personalContact\": {\n \"object\": \"contact\",\n \"id\": \"pmqpa2jwvdufjljaq6tty0oy\",\n \"firstName\": \"Martha\",\n \"lastName\": \"Flowers\",\n \"email\": \"martha@marthasflowers-test.com\",\n \"phone\": \"8312223333\",\n \"dateOfBirth\": \"08-30-1984\",\n \"status\": \"created\",\n \"created\": \"2017-02-21T23:27:26.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:26.000Z\"\n },\n \"additionalOwners\": [\n {\n \"personalTaxId\": \"123456789\",\n \"stakePercent\": \"30\",\n \"title\": \"CFO\",\n \"address\": {..},\n \"contact\": {..}\n }\n ],\n \"status\": \"active\",\n \"created\": \"2017-02-21T23:27:26.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:26.000Z\"\n },\n \"merchant\": {\n \"object\": \"merchant\",\n \"id\": \"wz4oi61p2hstk011ly3b1l01\",\n \"businessName\": \"Martha's FLowers\",\n \"businessUrl\": \"http://www.marthasflowers-test.com\",\n \"businessLogo\": \"http://www.marthasflowers-test.com/images/flowers.jpg\",\n \"supportEmail\": \"support@marthasflowers-test.com\",\n \"supportPhone\": \"8317778888\",\n \"supportUrl\": \"http://www.marthasflowers-test.com\",\n \"productDescription\": \"We sell flowers\",\n \"statementDescriptor\": \"Marthas Flowers\",\n \"defaultCurrency\": \"USD\",\n \"merchantCategoryCode\": \"12345\",\n \"businessAddress\": {\n \"object\": \"address\",\n \"id\": \"a64iiems4494kthtg8m5bqau\",\n \"street1\": \"123 account st\",\n \"street2\": \"3g\",\n \"city\": \"santa cruz\",\n \"state\": \"CA\",\n \"postalCode\": \"95060\",\n \"country\": \"USA\",\n \"status\": \"created\",\n \"created\": \"2017-02-21T23:27:25.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:25.000Z\"\n },\n \"personalContact\": {\n \"object\": \"contact\",\n \"id\": \"gnjxsvduqm1qj2a78sfubw88\",\n \"firstName\": \"Martha\",\n \"lastName\": \"Flowers\",\n \"email\": \"martha@marthasflowers-test.com\",\n \"phone\": \"8312223333\",\n \"dateOfBirth\": \"08-30-1984\",\n \"status\": \"created\",\n \"created\": \"2017-02-21T23:27:25.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:25.000Z\"\n },\n \"bank\": {\n \"object\": \"bank\",\n \"id\": \"qkjssrkv3yvvpsj5z340v4v2\",\n \"accountType\": \"checking\",\n \"bankName\": \"PayStand Test Bank\",\n \"routingNumber\": \"110000000\",\n \"nameOnAccount\": \"Martha Flowers\",\n \"accountHolderType\": \"company\",\n \"currency\": \"USD\",\n \"country\": \"USA\",\n \"last4\": \"6789\",\n \"fingerprint\": \"zefxwr581ahem2ek3vfjehki\",\n \"isDefault\": false,\n \"billingAddress\": {\n \"object\": \"address\",\n \"id\": \"mbmjr7yvk6ueq6ryv9f8xk62\",\n \"street1\": \"123 account st\",\n \"street2\": \"3g\",\n \"city\": \"santa cruz\",\n \"state\": \"CA\",\n \"postalCode\": \"95060\",\n \"country\": \"USA\",\n \"status\": \"created\",\n \"created\": \"2017-02-21T23:27:25.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:25.000Z\"\n },\n \"dropped\": false,\n \"verified\": false,\n \"status\": \"active\",\n \"created\": \"2017-02-21T23:27:25.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:26.000Z\"\n },\n \"status\": \"active\",\n \"created\": \"2017-02-21T23:27:25.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:26.000Z\"\n },\n \"settings\": {\n \"object\": \"settings\",\n \"id\": \"7krgkg4iuk7pjc3qs9fbbnfe\",\n \"events\": {\n \"enabled\": true,\n \"urls\": {\n \"always\": [\n \"http://api.marthasflowers-test.com/webhooks\"\n ]\n }\n },\n \"status\": \"active\",\n \"created\": \"2017-02-21T23:27:26.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:26.000Z\"\n },\n \"accountSettings\": {\n \"object\": \"settings\",\n \"id\": \"t8xswe8znw8zp7fs4o7phw9i\",\n \"events\": {\n \"enabled\": true,\n \"urls\": {\n \"always\": [\n \"http://api.platform-company-test.com/webhooks\"\n ]\n }\n },\n \"status\": \"active\",\n \"created\": \"2017-02-21T23:27:26.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:26.000Z\"\n },\n \"timezone\": \"UTC\",\n \"status\": \"active\",\n \"ownerId\": \"5lhbn6gvlmspmpo0jtkrnbm1\",\n \"created\": \"2017-02-21T23:27:25.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:28.871Z\"\n },\n \"application\": {\n \"object\": \"application\",\n \"id\": \"fca72a0f774a83ca1e3d159980f9abfd\",\n \"name\": \"Default application\",\n \"scope\": \"auth\",\n \"tokenType\": \"bearer\",\n \"grantTypes\": [\n \"authorization_code\",\n \"implicit\",\n \"client_credentials\",\n \"password\"\n ],\n \"restApiKey\": \"73dc00b612222222222220005a0335b7ea82bd957c\",\n \"status\": \"active\",\n \"created\": \"2017-02-21T23:27:29.000Z\",\n \"lastUpdated\": \"2017-02-21T23:27:29.000Z\",\n \"client_secret\": \"73dc00b61cb345234523452345234523452345bd957c\",\n \"client_id\": \"fca72a0f774a83ca1e3d123452345\",\n \"publishableKey\": \"fca72a0f774a83ca1e234523452345d\"\n }\n}", "language": "json", "name": "Response" } ], "sidebar": true } [/block]