GET https://:account.api-us1.com/api/3/deals/id
- cURL
curl --request GET \
--url https:///:account.api-us1.com/api/3/deals/id
- Node
var request = require("request");
var options = { method: 'GET',
url: 'https:///:account.api-us1.com/api/3/deals/id' };
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
- Ruby
require 'uri'
require 'net/http'
url = URI("https:///:account.api-us1.com/api/3/deals/id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
- JavaScript
var data = JSON.stringify(false);
var xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "https:///:account.api-us1.com/api/3/deals/id");
xhr.send(data);
- Python
import requests
url = "https:///:account.api-us1.com/api/3/deals/id"
response = requests.request("GET", url)
print(response.text)
200 with pipeline permission
{
"deal": {
"hash": "b107ee7e",
"owner": "1",
"contact": "45",
"organization": null,
"group": "2",
"stage": "3",
"title": "Demo Requested",
"description": "This is an important deal",
"percent": "0",
"cdate": "2017-01-31T08:23:52-06:00",
"mdate": "2017-02-28T16:11:29-06:00",
"nextdate": "2017-03-01T12:00:00-06:00",
"value": "34500",
"currency": "usd",
"status": "0",
"activitycount": "12",
"nextdealid": "1",
"edate": "0000-00-00 00:00:00",
"nexttaskid": "10",
"links": {
"dealActivities": "/api/3/deals/2/dealActivities",
"contact": "/api/3/deals/2/contact",
"contactDeals": "/api/3/deals/2/contactDeals",
"group": "/api/3/deals/2/group",
"nextTask": "/api/3/deals/2/nextTask",
"notes": "/api/3/deals/2/notes",
"organization": "/api/3/deals/2/organization",
"owner": "/api/3/deals/2/owner",
"scoreValues": "/api/3/deals/2/scoreValues",
"stage": "/api/3/deals/2/stage",
"tasks": "/api/3/deals/2/tasks"
},
"id": "2",
"nextTask": "10"
}
}
PATH PARAMS
id REQUIRED
int32 Deal's id
To retrieve a deal, the following permissions are required.
- Deal permission: the user should have permission to manage deals.
- Pipeline-specific permission: the user should have permission to manage the pipeline that the deal belongs to. If the user does not have the permission to manage the pipeline, limited deal data are returned with only
id
,title
, andisDisabled
set totrue
.
Opmerkingen
0 opmerkingen
Artikel is gesloten voor opmerkingen.