Forum Discussion
HASSANNAZEER
8 years agoFrequent Visitor
Api token
Can anyone help me with connecting this data source using API KEY http://developer.fulcrumapp.com
Phoenixke
8 years agoFrequent Visitor
As an example the users.json endpoint with GET:
let
request = Json.Document(Web.Contents("insert_url_here",
[Headers=[#"Accept"="application/json", #"Content-Type"="application/json", #"X-ApiToken"="insert_apikey_here"],
RelativePath = "/api/v2/users.json"]))[user]
in
request
This should return you a list of all 'user' records. I'm not sure if you need the ApiToken in this header or if you need the Authorization first and put that in.
HASSANNAZEER
8 years agoFrequent Visitor
This works fine. But all are labeled as Request
possible to use jquery ?
cURL
curl --request GET 'https://api.fulcrumapp.com/api/v2/records.json?form_id=my-form-id' \
--header 'Accept: application/json' \
--header 'X-ApiToken: my-api-key'
jQuery
$.ajax({
type: "GET",
url: "https://api.fulcrumapp.com/api/v2/records.json",
data: {
"form_id": "my-form-id"
},
contentType: "application/json",
dataType: "json",
headers: {
"X-ApiToken": "my-api-key"
},
success: function (data) {
// do something!
console.log(data);
}
});