Overview
The Sent Forms REST API allows Customers the ability to manage Sent Forms for their Company.
Note: Authorization Header above is the same as all other Mobile Forms REST API calls.
Note: API Developers can use OAuth 2.0 Authentication instead of the Basic Authentication. The OAuth 2.0 Authentication uses the Client Credentials Grant Type and requires the Company have a Client ID and a Client Secret generated in the Mobile Forms Portal to make web service calls to the REST API Endpoints. You can contact the Professional Services team at f2bps@field2base.com to implement OAuth 2.0 Authentication.
F2B API Prerequisites
To use the Sent Forms REST API, you need the following:
- An API Sync Key for the Company
- A User Account with the ability to submit to the API (Mobile Forms Administrator role)
Supported Operations
The following operations are supported by the REST web service.
Endpoint
| Method
| Description
|
onlinedocs/getsentforms
| POST
| Get a list of Sent Forms for a Form Template ID
Additional parameters are available
|
onlinedocs/sentforms/{resource ID}/PDF
| GET
| Retrieves a rendered PDF of a Sent Form
|
API Samples
Request: POST
Body
- {
- "templateId": "e8bac552-3486-47ff-87ed-6cfaf3c1c0fb",
- "searchLimit":1 // must be at least 1
- }
Body with Optional Parameters
- {
- "templateId": "e8bac552-3486-47ff-87ed-6cfaf3c1c0fb",
- "allUsers": "true", // defaults to false, true will only return a sent form from the logged in user
- "searchLimit":1, //must be at least 1
- "includeUnreleased": "true", //default is false
- "minTimestamp": "2021-02-01T00:00:00-05:00",
- "maxTimestamp": "2021-02-15T00:00:00-05:00",
- "data": [
- ["Page1@FirstName","equals","Joe"], //search types include: equals, startswith, endswith, contains
- ["Page1@LastName","contains","Schmoe"]
- ]
- }
Note: In order to use the "data" filtering option, Region Filters must first be created for the Form Template in the Portal (Admin > Form Templates > Region Filters) to capture the data. See the article on
Region Filters for details on how to create regions filters for a Form.
Currently, region filters are limited to 5 per form.
Response: 200 OK
- [
- {
- "ResourceId": "70599f64-d119-4a93-aea1-84622ccaa654",
- "FriendlyName": "Sample Timesheet - Job#: 15-201 - Supervisor 2 - Week Ending: 2/18/2021",
- "RefNum": 17150934,
- "RfiTimestamp": "2021-02-18T12:40:44.813",
- "WorkflowStatus": null,
- "IsClaimable": false
- }
- ]
Request: GET
Response:
PDF is returned as data in the contents of the body of the response with a content disposition of “inline”