added
2021-07-13 Adding filters on retrieving Projects in an Account
over 3 years ago by Api Dev
We have added filters on retrieving Projects in an Account. This means that you can specify if you want to retrieve "all", "active" or "deleted" projects in your account in the GET /api/v3/account/projects endpoint.
To filter on the status of the projects, add the HTTP Header Fieldwire-Filter as part of the request headers and specify if you want 'deleted', 'active', or 'all' projects for an account. If you don't specify anything or don't pass in the header at all then we default to 'active' projects which is the previous behavior. This means that it should continue to work as intended even if you don't use Fieldwire-Filter.
# Returns the active projects of an account.
curl --request GET \
--url https://console.fieldwire.net/api/v3/account/projects \
--header 'Accept: application/json'
--header 'Fieldwire-Filter: active'
# Returns the deleted projects of an account.
curl --request GET \
--url https://console.fieldwire.net/api/v3/account/projects \
--header 'Accept: application/json'
--header 'Fieldwire-Filter: deleted'
This change will go live on Tuesday (7/13/2021).