Can I create Google Doc using template and merge fields using API endpoints instead of using client? - google-docs

I have an existing template Google Doc with merge fields like {{First Name}} and I want to create a document using that template and fill the merge fields using values in javascript. Can I achieve this using the API endpoints instead of the client SDK or library?

Related

Can you send Custom field values (Pulled from HubSpot) from Tray.io to a DocuSign template?

I'm using a tray.io workflow where I'm pulling values from HubSpot to a Data Storage connector. I just want to know if it is possible to send those values to a DocuSign template provided. Like to be used as custom fields.

Multisigner separate readonly fields for a single document docusign

I want to assign a text field(read only) dynamically from code, separate for each recipient in a multi recipient embedded DocuSign using rest api (PHP SDK). How to do that using template role and tabs in php? or
How can I restrict certain fields from being viewed by specific recipients?
So your last question and the "single document" means you cannot use the DocuSign Visibility feature of DocuSign, I assume you know about that.
So, you can have readonly fields and you can have them assign to specific recipients, but other recipients will see them too.
You can also use pre-filled fields that enables to have a field that is not for any recipient and your code can fill it in.
What I recommend is this, since you need a template anyway. Create your template using the web app, make sure it works as you expect by trying it and sending documents to yourself using it.
Once you got it all working as expected in the web app, using the API is not that hard, all you have to do is get API logs of what the web app did using the API and you can do the same.

Save Docusign Document as Template through API

The docusign website allows for me to save a document as a template, but I have not been able to find a way to do this programmatically through the API. Is there a simple way to save a document as a template?
Yes, you can create a Template via the API by issuing this request:
POST /v2/accounts/{accountId}/templates
The API documentation contains details about this operation.
UPDATE
Do I understand correctly that your goal is to create a Template that's based upon an existing DocuSign Document, i.e., to mimic the following functionality in the DocuSign web UI?
If that's the case, then I'm not aware of any single API call that can do this. Instead, I believe you'll need to issue a series of API calls, to retrieve info about the existing Document(s) and then create the new Template using that info:
1) Get information about the existing DocuSign Document (envelope): GET /v2/accounts/{accountId}/envelopes/{envelopeId} (docs)
This operation returns recipient info (including tabs for each recipient) as well as envelope data like email subject, email body, reminders, etc. It also returns a documentsUri property that you can use to get the document(s) that belong to the envelope.
2) Get the list of document(s) that the envelope contains by issuing a GET request to the URI specified by the documentsUri from the prior response. (docs)
This operation returns information about each document in the specified envelope, but does not return document contents.
3) For each document listed in the prior API response, issue a GET request to the URI specified by the uri property for the document. (docs)
4) Finally, create a new Template using the data that you received in response to the previous API requests: POST /v2/accounts/{accountId}/templates (docs)
Note: As a final note -- if you're using one of the DocuSign SDKs, it's possible that there might be a function that you can call to implement this scenario, without having to piece together all of these API calls yourself. I'm not familiar enough with the SDKs to say whether or not they provide this type of functionality, but it'd be worth checking for, if you're using an SDK.

How can my application retrieve custom fields from a DocuSign transaction?

I am working with DocuSign custom fields. I want to get all my custom fields that were created in the admin console by using a REST API call.
Is there any REST call to get all the custom fields?
I believe you're wanting the information that you've set up displayed in JSON via REST.
endpoint: GET https://{server}/restapi/v2/accounts/{accountId}/custom_fields
This will return your textCustomFields and listCustomFields

C# classes for creating DocuSign Envelope using REST

I was wondering if there was sample base classes for creating an Envelope using the REST API for DocuSign.
What we are trying to accomplish is to be able to instantiate and Envelope object and add the necessary templates and document to it kind of like you do with SOAP but using the REST API.
I could try to copy the JSON sample that they have on the DocuSign Documentation and convert those to classes and go from there but was wondering if there is a more complete sample out there as we'll need to pull templates, modify the values on the tabs and combine templates with documents before sending the Envelope for signing.
Updated Answer with all of the currently offered REST DocuSign SDK's
C# SDK
Java SDK
PHP
SDK
Node
SDK
Python
SDK
Ruby
SDK
Objective C
SDK

Resources