Skip to content

Latest commit

 

History

History
58 lines (37 loc) · 1.56 KB

LeadSourcesApi.md

File metadata and controls

58 lines (37 loc) · 1.56 KB

Pipedrive.LeadSourcesApi

All URIs are relative to https://api.pipedrive.com/v1

Method HTTP request Description
getLeadSources GET /leadSources Get all lead sources

getLeadSources

GetLeadsSourceResponse getLeadSources()

Get all lead sources

Returns all lead sources. Please note that the list of lead sources is fixed, it cannot be modified. All leads created through the Pipedrive API will have a lead source `API` assigned.

Example

import Pipedrive from 'pipedrive';
let apiClient = new Pipedrive.ApiClient();
// Configure API key authorization: api_key
let api_key = apiClient.authentications['api_key'];
api_key.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//api_key.apiKeyPrefix = 'Token';
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = apiClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';

let apiInstance = new Pipedrive.LeadSourcesApi(apiClient);
apiInstance.getLeadSources().then((data) => {
  console.log('API called successfully. Returned data: ' + data);
}, (error) => {
  console.error(error);
});

Parameters

This endpoint does not need any parameter.

Return type

GetLeadsSourceResponse

Authorization

api_key, oauth2

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json