How to get list entity by name
• 1 minute to read
The List endpoint, as exposed by the Agent API and proxy clients, uses Named lists, or methods, to obtain a list entity and list items.
The follow examples demonstrate how to get the Category list entity.
GET https://{{env}}.superoffice.com/{{tenant}}/api/v1/List/Category
Authorization: Bearer {{token}}
Accept: application/json; charset=utf-8
POST https://{{env}}.superoffice.com/{{tenant}}/api/v1/Agents/List/GetListEntityByName HTTP/1.1
Authorization: Bearer {{token}}
Accept: application/json; charset=utf-8
Content-Type: application/json; charset=utf-8
{
"Name": "Category",
}
Get a list entity using the SuperOffice.WebApi proxy client.
var config = new WebApiOptions(tenant.WebApiUrl);
config.Authorization = new AuthorizationAccessToken("8A:Cust12345.Example-Token", OnlineEnvironment.SOD);
var agent = new ListAgent(config);
var listEntity = agent.GetListEntityByNameAsync("Category").Result;
Back