Tuesday, 15 January 2013

json - PandaDOC API PHP issue -


I am pulling my hair with the Paddock API to send contracts to my customers.

I have this work and the email and the recipient are going through the information, but I am unable to add it to custom areas. I've tried many ways.

Below are the requests I need to say:

  {"name": "sample document", "url": "URL_TO_A_DOCUMENT", "recipient": [{"Email": "john.appleseed@yourdomain.com", "first_name": "john", "lastname": "Applied", "role": "u1"},. ...], "Field": {"optId": {"title": "Field 1"}}}  

Here's my PHP in:

function - pandadoc ($ access_token, $ array) {$ url = 'https://api.pandadoc.com/public/v1/documents'; $ Docurl = "http://www.mydomain.co.uk/pandadoc/marktest.pdf"; $ Postfilled = array (); $ Postfield ['name'] = 'contract name'; $ Postfile ['url'] = $ docurl; $ Postfields ['Recipient'] = Array (array ('email' = & gt; 'customer@customeremail.com', 'first_name' = & gt; 'John', 'last_name' =>, 'Applied', ' Role '= & gt;' u1 ')); $ Postfields ['fields'] = array ('plFirstname' = & gt; array ('first name' => gt; john));

If I comment on the field segment - it goes to the correct email and the customer can sign, but I should be able to pass in the RelayTrain custom areas as well.

P> Maybe you already Solved, but for any person answering, I got to do this work:

  "fields": {"fieldId": {"assignee": "role @ email , "Title": "title for field"}, ...}  

No comments:

Post a Comment