The base URL results from your client and the ID of the form: "https: //www.brandsmill.de/#webform? M = ... & id = ... Further parameters follow with & ....
https://www.brandsmill.de/#webform?m=<mandantNr>&id=<formularId>&bg=fffff&bgr=ffffff&bgh=66001f&bgt=ffffff&w=900&fh=600
?m=<client no> Your client
&id=<form id> ID of the Form
&ct= save to contact by contact id
&ctm= save to contact by contact E-Mail
&bg=background color form
&bgr=background color form row
&bgh=background color title
&bgt=background color info
&l=label width
&w=total form width
&fh=total form hight
&f=F123:abc,F124:efg,..
&md=a
Mode 'a' Save automatically (saves the values directly with the call)
Die Folgende URL (fett geschriebener Text ist anzupassen) könnte man in der E-Mail Signatur hinterlegen:
The following URL (bold text can be customized) could be stored in the e-mail signature:
https://www.brandsmill.com/#webform?m=<clientno>&id=<formId>&bg=fffff&bgr=ffffff&bgh=66001f&bgt=ffffff&w=900&fh=600&md=a&f=F354:<$cid>
The link could e.g. bear the name "unsubscribe". If the recipient clicks on it, the form with the assignment to the contact starts and the workflow rules then control what should happen.
<$cid> is a placeholder for the contact in whose context a task was started. This saves field F354 with the contact assignment.
<!doctype html>
<html>
<head>
<!-- (A) handle Data via API as UTF-8 encoded -->
<meta charset='utf-8' />
<title>brand's mill Form API</title>
</head>
<body>
<h2>Send fields to brand's mill webform</h2>
Keep your design and start any Workflow on brand's mill using our API.
<br>
<br>
<div>
<input
id="insertForm"
type="submit"
value="send data via JSON">
<br>
<br>
Data will be persisted within brand's mill and forwarded via a workflow within brand's mill.
<br>
You need to define a 'Webform' and its 'Workflow' within brand's mill to handle the data you send from your site.
<br>
The 'Webform' fields are those you have to target as 'F...' fields.
<br>
<br>
Inspect source of this HTML to find out details. You may use this API in conjunction with a brand's mill subscribtion.
<br>
<br>
(c) brand's mill 2015
</div>
<script type="text/javascript">
function init() {
var callback = function() {
console.log("loaded");
}
gapi.client.load('bmform', 'v1', callback, 'https://brandsmill-service.appspot.com/_ah/api');
document.getElementById('insertForm').onclick = function() {
saveForm();
}
}
function saveForm() {
/* (C) send the fields to brand's mill via JSON API */
/* (1) Client ID - Tenant of the brand's mill company */
var clientID ="Mandant Nr.";
/* (2) Form ID - ID of the Webform as shown in the webform URL */
var formID = "Webformular id"
/* (3) JSON of all Fields find the target "F..." in the webform you target within brand's mill */
var formFields = "{\"F88\":\"Jäger, Malte\"},{\"F89\":\"Brand's mill GmbH\"},{\"F95\":\"bitte um Rückruf\"}";
var requestData = {};
requestData.json = "{\"client\":\""+clientID+"\",\"form\":\""+formID+"\",\"fields\":["+formFields+"]}";;
gapi.client.bmform.post(requestData).execute(function(resp) {
if (!resp.code) {
console.log(resp);
} else {
console.log(resp.code + " : " + resp.message);
alert("Error : " + resp.code + ":" + resp.message);
}
});
}
</script>
<!-- (B) load and init API -->
<script src="https://apis.google.com/js/client.js?onload=init"></script>
</body>
</html>