When requesting an organization by key, I don’t see where the phone numbers, email addresses, and addresses are listed.
I checked the docs and there’s no information about what I can “$expand”.
Here’s what I see in Karbon:
Here’s the request I made:
url = "https://api.karbonhq.com/v3/Organizations/xxxxxxxxxx?$expand=Contacts"
payload={}
headers = {
'Accept': 'application/json',
'Authorization': 'Bearer xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text)
Here’s the resulting code form an API request:
{
"@odata.context": "https://api.karbonhq.com/v3/$metadata#Organizations/KarbonService.OrganizationDTO(Contacts())/$entity",
"@odata.type": "#KarbonService.OrganizationDTO",
"OrganizationKey": "xxxxxxxxxx",
"FullName": "test full name",
"ClientOwner": null,
"ClientManager": null,
"ContactType": null,
"UserDefinedIdentifier": null,
"RestrictionLevel": "Public",
"LastModifiedDateTime": "2023-02-04T15:57:57Z",
"EntityDescription": {
"Text": "abc123"
},
"AccountingDetail": {
"ContactPermaKey": null,
"OrganizationPermaKey": "xxxxxxxxxx",
"BirthDate": null,
"DeathDate": null,
"Salutation": null,
"Sex": null,
"FinancialYearEndDay": null,
"FinancialYearEndMonth": null,
"IncorporationDate": null,
"IncorporationState": null,
"LegalName": null,
"LineOfBusiness": null,
"EntityType": null,
"TaxCountryCode": "US",
"TradingName": null,
"AnnualRevenue": null,
"BaseCurrency": null,
"GstBasis": null,
"GstPeriod": null,
"IncomeTaxInstallmentPeriod": null,
"IsVATRegistered": null,
"OrganizationValuation": null,
"PaysTax": null,
"PrepareGST": null,
"ProvisionalTaxBasis": null,
"ProvisionalTaxRatio": null,
"RevenueModel": null,
"SalesTaxBasis": null,
"SalesTaxPeriod": null,
"Sells": null,
"RegistrationNumbers": t],
"Notes": ]
},
"Contacts": ]
}
cc: