GetCountByServiceId()
Retrieve the number of service requests filtered by service id
Description
This method is used to retrieve the int number of service requests that are filtered by service ID. Overrides include the ability to further filter by organization ID.
Package Details
Interface
IServiceRequestManager
Syntax
ServiceRequestManager.GetCountByServiceId(int serviceId);
ServiceRequestManager.GetCountByServiceId(int serviceId, int organizationId);
Returns
Task<int>
API Endpoint
[GET] /api/v1/users/{id}/servicerequests
Parameters
Parameter | Description | Type |
---|---|---|
serviceId | id of the current service | int |
organizationId | id of the organization | int |
Returns
200 - Ok
Example
using MTOA.BLL.Interfaces;
int serviceId = 123;
int organizationId = 567;
var serviceRequestCount = await _serviceRequestManager.GetCountByServiceId(serviceId, organizationId);