DocuSign: How to add recipientSignatureProviderInfo to the payload text/csv of Bulkrecipients - csv

I can see that in the REST API documentation on bulkrecipients, the object recipientSignatureProviderInfo can be added to the JSON payload :
{
"bulkRecipients": [
{
"rowNumber": "sample string 1",
"email": "sample string 2",
"name": "sample string 3",
"note": "sample string 4",
"accessCode": "sample string 5",
"identification": "sample string 6",
"phoneNumber": "sample string 7",
"tabLabels": [
{
"name": "sample string 1",
"value": "sample string 2"
}
],
"recipientSignatureProviderInfo": [
{
"name": "sample string 1",
"value": "sample string 2"
}
]
}
]
}
But what is the correct way to add this to a text/csv content-type ?
for example :
Name,Email,Note,AccessCode,Identification,PhoneNumber,address1
David Jones,david.jones#yahoo.com,Here is the document we discussed.,,ID Check,,123 Main St
Kevin Smith,kevinmith#yahoo.com,,2243,,,697 My Way
Elisabeth Bozick,elisabeth.bozick#yahoo.com,,,phone,usersupplied,827 1st Ave
Whta is the correct header name ? I tried "recipientSignatureProviderInfo" but that didn't seem to work.
Thanks in advance !

The recipientSignatureProviderInfo column is not supported in the Bulk recipient CSV file.
Here is the link to Documentation
Only the following columns are supported.
Name
Email
Note
AccessCode
Identification
PhoneNumber
DocuSign Field Name
Additional resources.
https://support.docusign.com/guides/ndse-user-guide-send-a-document-using-bulk-send

Related

Is there a way where all the values from a JSON column can be used as query params to fetch values in db?

I have a lookup table with columns old_item_code, description, new_item_code.
Now my items is an array of objects.
"items":[
{
"code": "OLDCODE1",
"description": "sample description1",
"value": "Sample value1"
},
{
"code": "OLDCODE2",
"description": "Sample Description2",
"value": "Sample Value 2"
}
]
Now I want my items array to be replaced with new item code which has to be queried from the lookup table(postgres).
I want my final result to be like
"items": [
{
"NEWCODE1": "Sample Value 1",
"NewCODE2": "Sample Value 2"
}
]
In PSQL, using where with array will get you the new code. Use a map to get its values.

display data in codenameoone using table

am making a mobile app using codenameone and i want to display the data from database which i get the following json response using asp.net api
{
"FullNames": "sample string 1",
"PhoneNumber": "sample string 2",
"Date": "sample string 3",
"PickupPoint": "sample string 4",
"Destination": "sample string 5",
"Reason": "sample string 6",
"Time": "sample string 7",
"Booking": "sample string 8"
}
You can parse the JSON using Properties or the JSON parser. Both are supported by the Rest API which returns a map or a PropertyBusinessObject respectively.
The Table is the simple part. You can create it with the Table class.
A super trivial implementation would look something like:
DefaultTableModel model = new DefaultTableModel(
new String[] {"Name", "Value"},
new Object[][] {
{ "Full Name", UserInfo.fullName.get() },
{ "Phone Number", UserInfo.phoneNumber.get() },
...
}
) {
public boolean isEditable(int row, int column) { return column == 1; }
};
Table table = new Table(model);
Form f = new Form("My Table", new BorderLayout());
f.add(CENTER, table);
f.show();
Now notice that we have an automatic UI option that generates a table of business objects for you: https://www.codenameone.com/blog/table-property-mapping.html
But this works for a list of business object, not for an individual object.

jdbcTemplate - Convert data from JSON column

Tools: Spring Booot v2.1.3.RELEASE, MySQL 5.7
I have table with column of type JSON named "properties".
I use jdbcTemplate.queryForList(sql) method to read from this table.
Rest service returns something like this:
[
{
"id": 1,
"name": "users",
"properties": "{\"prop1\": \"value1\"}",
"description": "smpl descr1",
"log_enabled": false
},
{
"id": 2,
"name": "members",
"properties": null,
"description": "sample description 2",
"log_enabled": true
}
]
As you can see the "properties" object is type of String.
How to force jdbcTemplete to convert data from JSON column into JSON instead of String?
Expected result:
[
{
"id": 1,
"name": "users",
"properties": {
"prop1": "value1"
},
"description": "smpl descr1",
"log_enabled": false
},
{
"id": 2,
"name": "members",
"properties": null,
"description": "sample description 2",
"log_enabled": true
}
]
I am sorry that JdbcTemplete does not have such function. You have to convert the JSON string to the java object by yourself using your favourite JSON library.
For example , in case of Jackson , you can convert any JSON string to a Map using:
ObjectMapper mapper = new ObjectMapper();
String json = "{\"prop1\": \"value1\" , \"prop2\": 123}";
Map<String,Object> result = mapper.readValue(json,new TypeReference<Map<String,Object>>() {});
result.get("prop1") // "value1"
result.get("prop2") // 123

How to create nested object in MongoDB schema, nested object and array MEAN stack

I'm trying to design a nested MongoDB schema.
Currently, I have this schema and it's working:
var CompanySchema = new mongoose.Schema({
name: String,
rate: number
date: Date
})
But I wanna expend it to get:
var CompanySchema = new mongoose.Schema({
name: String,
currency: {
mxn: Number,
php: Number,
},
source: [String],
deliveryMethod: [String],
date: Date
})
For source, I want to get an array of inputs ex. ["bank", "debit card", "agent"]
and almost samething for deliverymethod.
But either my input is wrong or my schema, because the value for source saves as one long string, not a separated value.
Also, I think the way I designed the currency to have more currency rate is correct but I don't know how my input json should suppose to be.
I tried it in postman:
{
"name": "google",
"currency": {
"mxn": 20,
"php": 30
}
}
and this is the result i got:
{
"status": 201,
"data": {
"__v": 0,
"name": "google",
"date": "2017-12-06T22:38:45.896Z",
"_id": "5a2871752e3b7343dc388549",
"deliveryMethod": [
null
],
"source": [
null
]
},
"message": "Succesfully Created Company"
}
1- if my currency nested schema is correct how should be my post json file be?
2- how can I get source and deliveryMethod as an array of string?
The JSON in the request body should look like this:
{
"name": "google",
"currency": {
"mxn": 20,
"php": 30
},
"source": ["source1", "source 2", "source 3"],
"deliveryMethod": ["delMetd 1", "delMetd 2", "delMetd 3"],
"date": "2015-11-27T23:00:00Z"
}
I copy/pasted your code and tried with Postman. The response I got back was:
{
"__v": 0,
"name": "google",
"date": "2015-11-27T23:00:00.000Z",
"_id": "5a2915295c5f714f7cb25d90",
"deliveryMethod": [
"delMetd 1",
"delMetd 2",
"delMetd 3"
],
"source": [
"source1",
"source 2",
"source 3"
],
"currency": {
"mxn": 20,
"php": 30
}
}
If I connect to the database with the mongo shell and run db.companies.find().pretty() I get this result:
{
"_id" : ObjectId("5a2915295c5f714f7cb25d90"),
"name" : "google",
"date" : ISODate("2015-11-27T23:00:00Z"),
"deliveryMethod" : [
"delMetd 1",
"delMetd 2",
"delMetd 3"
],
"source" : [
"source1",
"source 2",
"source 3"
],
"currency" : {
"mxn" : 20,
"php" : 30
},
"__v" : 0
}
Your schema is fine. You can try dropping the collection (db.companies.drop()) if you can't get it to work. Start with a fresh one if you don't have any important data in it.

Get the parent object to use in dojo widget

I am trying to parse the json result object and use html template in a widget to display.
The json looks like this
Result": [
{
"Website": "Testing ",
"Description": "Content from yahoo ",
"LinkGroup": {
"entry": [
{
"linkType": "information",
"Link": {
"title": "Test1",
"url": "http://yahoo.com",
"description": "my Link Description"
}
},
{
"linkType": "news link",
"Link": {
"title": "Test 2",
"url": "http://www.yahoo.com/news link...",
"description": "news link Link Description"
}
}
]
}
},
{
"Website": "Testing 2",
"Description": "Content from google ",
"LinkGroup": {
"entry": [
{
"linkType": "information",
"Link": {
"title": "Test1",
"url": "http://google.com",
"description": "my Link Description"
}
},
{
"linkType": "news link",
"Link": {
"title": "Test 2",
"url": "http://www.google.com/news link...",
"description": "news link Link Description"
}
}
]
}
},
I was earlier able to parse just the entry items and used it on a templated widget. I would now like to use the Website and Description object within my widget. Instead of the entry array object I tried to parse the Result object and tried to access the entry. Looking at the console log I see it stops when it tries to get the entry value. I am wondering how to parse it so I can first get the website and description and then add the entry items within that.
This is my html widget code
<div><span title="${Link.description}">${Link.description</span>/div> <br />
${Link.title}<br />
and I parse the json with this code
request("js/my/data/sample.json", {
handleAs: "json"}).then(function(jsonResults){
arrayUtil.forEach(jsonResults.LinksGroup, function(List)
{arrayUtil.forEach(List.LinksGroup.entry, function(Ientry){
var widget = new support(Ientry).placeAt(authorContainer);
});});
I found the answer. I used another widget within the array before the entry object which did the trick.