API Autotask — contrats de service
Lire les contrats de service de Autotask depuis votre application, par une simple requête HTTP : pas de SDK, pas d’ODBC. Conexio relaie l’appel vers Autotask et vous répond en JSON — entité CustomerServiceContract.
✓ Lire (GET)✗ Créer (POST)✗ Modifier (PUT)
Lire les contrats de service
Une requête GET sur /api/Entity/CustomerServiceContract, avec les modificateurs $select, $filter et $top. L’en-tête ALLOW_PAGINATION renvoie { Data, ResultsCount, TotalCount }.
GET https://gateway.conexio.dev/api/Entity/CustomerServiceContract?$select=ServiceContractId,ServiceContractCode,ServiceContractName,SourceSystem,LastModifiedDate&$filter=LastModifiedDate ge '2026-01-01'&$top=10
Authorization: Basic base64(CODE_LICENCE:CLE_API)
COMPANY_CODE: VOTRE_COMPAGNIE
ALLOW_PAGINATION: truecurl 'https://gateway.conexio.dev/api/Entity/CustomerServiceContract?$select=ServiceContractId,ServiceContractCode,ServiceContractName,SourceSystem,LastModifiedDate&$filter=LastModifiedDate%20ge%20'2026-01-01'&$top=10' \
-u "$CONEXIO_LICENCE:$CONEXIO_API_KEY" \
-H 'COMPANY_CODE: VOTRE_COMPAGNIE' \
-H 'ALLOW_PAGINATION: true'const response = await fetch("https://gateway.conexio.dev/api/Entity/CustomerServiceContract?$select=ServiceContractId,ServiceContractCode,ServiceContractName,SourceSystem,LastModifiedDate&$filter=LastModifiedDate%20ge%20'2026-01-01'&$top=10", {
headers: {
Authorization: "Basic " + btoa(`${CODE_LICENCE}:${CLE_API}`),
COMPANY_CODE: "VOTRE_COMPAGNIE",
ALLOW_PAGINATION: "true",
},
})
const { Data, TotalCount } = await response.json()C# et Python
var http = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Get, "https://gateway.conexio.dev/api/Entity/CustomerServiceContract?$select=ServiceContractId,ServiceContractCode,ServiceContractName,SourceSystem,LastModifiedDate&$filter=LastModifiedDate%20ge%20'2026-01-01'&$top=10");
request.Headers.Authorization = new AuthenticationHeaderValue("Basic",
Convert.ToBase64String(Encoding.UTF8.GetBytes($"{codeLicence}:{cleApi}")));
request.Headers.Add("COMPANY_CODE", "VOTRE_COMPAGNIE");
request.Headers.Add("ALLOW_PAGINATION", "true");
var json = await (await http.SendAsync(request)).Content.ReadAsStringAsync();import requests
response = requests.get(
"https://gateway.conexio.dev/api/Entity/CustomerServiceContract?$select=ServiceContractId,ServiceContractCode,ServiceContractName,SourceSystem,LastModifiedDate&$filter=LastModifiedDate%20ge%20'2026-01-01'&$top=10",
auth=(CODE_LICENCE, CLE_API),
headers={"COMPANY_CODE": "VOTRE_COMPAGNIE", "ALLOW_PAGINATION": "true"},
)
data = response.json()["Data"]Filtrer
Les champs filtrables de CustomerServiceContract sur Autotask, et leurs opérateurs $filter :
| Champ | Opérateurs |
|---|---|
ServiceContractId | eq ne in gt ge lt le |
ServiceContractCode | eq ne in contains |
ServiceContractName | eq ne in contains |
SourceSystem | eq ne in contains |
LastModifiedDate | eq ne in gt ge lt le |
Description | eq ne in contains |
InternalShortNote | eq ne in contains |
ContractStartDate | eq ne in gt ge lt le |
ContractEndDate | eq ne in gt ge lt le |
DurationInMonths | eq ne in gt ge lt le |
IsHistorical | eq ne |
CustomerId | eq ne in |
CustomerCode | eq ne in contains |
CustomerExternalId | eq ne in |
CustomerName | eq ne in contains |
CustomerContactName | eq ne in contains |
InvoicingCustomerId | eq ne in |
InvoicingCustomerCode | eq ne in contains |
InvoicingCustomerName | eq ne in contains |
InvoicingContactName | eq ne in contains |
StatusName | eq ne in contains |
IsActive | eq ne |
ContractTypeName | eq ne in contains |
ContractCategoryName | eq ne in contains |
ContractPeriodTypeName | eq ne in contains |
BillingPreferenceName | eq ne in contains |
LineOfBusinessName | eq ne in contains |
ServiceLevelAgreementName | eq ne in contains |
PurchaseOrderNumber | eq ne in contains |
SetupFee | eq ne in gt ge lt le |
SetupFeeBillingCodeName | eq ne in contains |
OverageBillingRate | eq ne in gt ge lt le |
EstimatedRevenue | eq ne in gt ge lt le |
EstimatedCost | eq ne in gt ge lt le |
EstimatedHours | eq ne in gt ge lt le |
IsDefaultContract | eq ne |
IsCompliant | eq ne |
RenewedContractId | eq ne in |
ExclusionContractId | eq ne in |
LineCount | eq ne in gt ge lt le |
RecurringMonthlyValue | eq ne in gt ge lt le |
RecurringAnnualValue | eq ne in gt ge lt le |
RecurringValuePerPeriod | eq ne in gt ge lt le |
Les champs
| Champ | Lire | Créer | Modifier |
|---|---|---|---|
ServiceContractId | ✓ | — | — |
ServiceContractCode | ✓ | — | — |
ServiceContractName | ✓ | — | — |
SourceSystem | ✓ | — | — |
LastModifiedDate | ✓ | — | — |
ServiceContractVersionId | — | — | — |
Description | ✓ | — | — |
InternalShortNote | ✓ | — | — |
ContractStartDate | ✓ | — | — |
ContractEndDate | ✓ | — | — |
DurationInMonths | ✓ | — | — |
IsHistorical | ✓ | — | — |
CustomerId | ✓ | — | — |
CustomerCode | ✓ | — | — |
CustomerExternalId | ✓ | — | — |
CustomerName | ✓ | — | — |
CustomerContactName | ✓ | — | — |
InvoicingCustomerId | ✓ | — | — |
InvoicingCustomerCode | ✓ | — | — |
InvoicingCustomerExternalId | — | — | — |
InvoicingCustomerName | ✓ | — | — |
InvoicingContactName | ✓ | — | — |
StatusName | ✓ | — | — |
IsActive | ✓ | — | — |
ContractTypeName | ✓ | — | — |
ContractCategoryName | ✓ | — | — |
ContractPeriodTypeName | ✓ | — | — |
BillingPreferenceName | ✓ | — | — |
LineOfBusinessName | ✓ | — | — |
ServiceLevelAgreementName | ✓ | — | — |
PurchaseOrderNumber | ✓ | — | — |
SetupFee | ✓ | — | — |
SetupFeeBillingCodeName | ✓ | — | — |
OverageBillingRate | ✓ | — | — |
EstimatedRevenue | ✓ | — | — |
EstimatedCost | ✓ | — | — |
EstimatedHours | ✓ | — | — |
IsDefaultContract | ✓ | — | — |
IsCompliant | ✓ | — | — |
RenewedContractId | ✓ | — | — |
ExclusionContractId | ✓ | — | — |
LineCount | ✓ | — | — |
RecurringMonthlyValue | ✓ | — | — |
RecurringAnnualValue | ✓ | — | — |
RecurringValuePerPeriod | ✓ | — | — |
SCContractType | — | — | — |
SCInvoicingMode | — | — | — |
SCPeriodIntervalBetweenInvoices | — | — | — |
SCPeriodicity | — | — | — |
SCProductGroupAttached | — | — | — |
PayePar | — | — | — |
IsTravellingFeeIncluded | — | — | — |
IsHourlyFeesIncluded | — | — | — |
PeriodTotalAmt | — | — | — |
ExtendedProperties | ✓ | — | — |
Lines[].ServiceContractLineId | ✓ | — | — |
Lines[].ServiceContractId | ✓ | — | — |
Lines[].LineType | ✓ | — | — |
Lines[].ServiceId | ✓ | — | — |
Lines[].ServiceName | ✓ | — | — |
Lines[].ServiceSku | ✓ | — | — |
Lines[].ServiceExternalId | ✓ | — | — |
Lines[].DescriptionService | ✓ | — | — |
Lines[].BillingCodeName | ✓ | — | — |
Lines[].VendorName | ✓ | — | — |
Lines[].DescriptionInternal | ✓ | — | — |
Lines[].DescriptionInvoice | ✓ | — | — |
Lines[].PeriodTypeName | ✓ | — | — |
Lines[].PeriodsPerYear | ✓ | — | — |
Lines[].UnitPriceList | ✓ | — | — |
Lines[].UnitPrice | ✓ | — | — |
Lines[].UnitPriceAdjusted | ✓ | — | — |
Lines[].UnitCost | ✓ | — | — |
Lines[].Units | ✓ | — | — |
Lines[].UnitPriceCurrentPeriod | ✓ | — | — |
Lines[].UnitCostCurrentPeriod | ✓ | — | — |
Lines[].UnitsPeriodStartDate | ✓ | — | — |
Lines[].UnitsPeriodEndDate | ✓ | — | — |
Lines[].ExtendedPrice | ✓ | — | — |
Lines[].ExtendedCost | ✓ | — | — |
Lines[].DiscountPercent | ✓ | — | — |
Lines[].MonthlyValue | ✓ | — | — |
Lines[].AnnualValue | ✓ | — | — |
Lines[].QuoteItemId | ✓ | — | — |