Forms

Binary documents with field’s map to fill


Parameters

Name In Type Required Description
org_id path string true The string id related with one of Grupo MasOrange tenants
body body object true File name, content and metadata for creating the form.

Request body - Content-Type: multipart/form-data

Custom schema example

1
2
3
4
5
6
name: customer_contract
extension: pdf
tags:
  - DRAFT
content: string

Name Type Required Description
name string true Name of the form (without spaces). The form is renamed with this value (will be normalized on form external Id).
extension string true Format of the form to be stored. It must match the format of the binary
Allowed values: pdf
tags array false Five free values (user-defined) to tag form. These values are normalized following the next rules:
  • All tags will be converted to uppercase
  • All whitespaces will be removed
  • Empty or blank tags are not allowed
  • Tags matching reserved words (null, undefined or nan) are not allowed|
    |content|string|true|Document content in binary format|

Request example

1
2
3
4
5
6
7
8
9

curl -X POST https://documents.masstack.com/v1/orgs/masmovil/templates/forms \
  -H "Content-Type: multipart/form-data" \
  -H "Accept: application/json" \
  -F "name=customer_contract" \
  -F "extension=pdf" \
  -F "tags=undefined" \
  -F "content=undefined" \

Responses

Code Meaning Description Schema
201 Created New form is created. Expected response for a valid request. FormFieldResponse
400 Bad Request Request input is not valid None
401 Unauthorized Unauthorized. AuthN and AuthZ validations have fail None
409 Conflict Conflict. Resource already exits None
422 Unprocessable Entity Request input can not be processed (is incomplete) None
500 Internal Server Error Not expected error None
default Default Error response ErrorsResponse

Parameters

Name In Type Required Description
org_id path string true The string id related with one of Grupo MasOrange tenants
page query Page false Defines forms page number to be show. If not defined, default value is 0 (first page).
pageSize query PageSize false Defines the number of forms returned in each page. If not defined, default value is 50.

Request example

1
2
3
4

curl -X GET https://documents.masstack.com/v1/orgs/masmovil/templates/forms?page='0'&pageSize='1' \
  -H "Accept: application/json"

Responses

Code Meaning Description Schema
200 OK The forms metadata is returned. Expected response for a valid request. AllFormsResponse
400 Bad Request Request input is not valid None
401 Unauthorized Unauthorized. AuthN and AuthZ validations have fail None
404 Not Found resource not found None
410 Gone resource is not longer available None
500 Internal Server Error Not expected error None
default Default Error response ErrorsResponse

Parameters

Name In Type Required Description
org_id path string true The string id related with one of Grupo MasOrange tenants
formReference path string true The external id or id of the form
body body FillFormRequest true values to fill a form

Request body - instance of FillFormRequest

1
2
3
4
5
6
7
8
9
{
  "fieldsValues": [
    {
      "name": "string",
      "value": "string"
    }
  ],
  "fillMode": "default"
}
Name Type Required Description
fieldsValues FieldsValues true form variables whose values will be printed in the filled form
fillMode FillMode false Allowed values: ‘default’, ‘raw’
Describes character’s filter process to execute when fill a form/template:
- ‘default’ (also when no value or unrecognized value): all non alfa-numeric characters are escaped and replaced by ‘?'
- ‘raw’: like ‘default’ but ‘tabulation’ and ‘end of line’ characters are allowed

Request example

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14

curl -X POST https://documents.masstack.com/v1/orgs/masmovil/templates/forms/d290f1ee-6c54-4b01-90e6-d701748f0851,form_name/fill \
  -H "Content-Type: application/json" \
  -H "Accept: application/octet-stream" \
 --data-raw "{
  'fieldsValues': [
    {
      'name': 'string',
      'value': 'string'
    }
  ],
  'fillMode': 'default'
}" 

Responses

Code Meaning Description Schema
200 OK The filled form as pdf document. Expected response to a valid request. string
400 Bad Request Request input is not valid None
401 Unauthorized Unauthorized. AuthN and AuthZ validations have fail None
404 Not Found resource not found None
410 Gone resource is not longer available None
500 Internal Server Error Not expected error None
default Default Error response ErrorsResponse

Parameters

Name In Type Required Description
org_id path string true The string id related with one of Grupo MasOrange tenants
formReference path string true The string ‘id’ or ‘external id’ of the desired form

Request example

1
2
3
4

curl -X GET https://documents.masstack.com/v1/orgs/masmovil/templates/forms/d290f1ee-6c54-4b01-90e6-d701748f0851,form_name/metadata \
  -H "Accept: application/json"

Responses

Code Meaning Description Schema
200 OK The form metadata is returned. Expected response for a valid request. FormFieldResponse
400 Bad Request Request input is not valid None
401 Unauthorized Unauthorized. AuthN and AuthZ validations have fail None
404 Not Found resource not found None
410 Gone resource is not longer available None
500 Internal Server Error Not expected error None
default Default Error response ErrorsResponse

Parameters

Name In Type Required Description
org_id path string true The string id related with one of Grupo MasOrange tenants
formReference path string true The string ‘id’ or ‘external id’ of the desired form

Request example

1
2
3
4

curl -X GET https://documents.masstack.com/v1/orgs/masmovil/templates/forms/d290f1ee-6c54-4b01-90e6-d701748f0851,form_name \
  -H "Accept: application/octet-stream"

Responses

Code Meaning Description Schema
200 OK The form binary content. Expected response to a valid request. string
400 Bad Request Request input is not valid None
401 Unauthorized Unauthorized. AuthN and AuthZ validations have fail None
404 Not Found resource not found None
410 Gone resource is not longer available None
500 Internal Server Error Not expected error None
default Default Error response ErrorsResponse

Parameters

Name In Type Required Description
org_id path string true The string id related with one of Grupo MasOrange tenants
formReference path string true The string ‘id’ or ‘external id’ of the desired form

Request example

1
2
3
4

curl -X DELETE https://documents.masstack.com/v1/orgs/masmovil/templates/forms/d290f1ee-6c54-4b01-90e6-d701748f0851,form_name \
  -H "Accept: application/json"

Responses

Code Meaning Description Schema
204 No Content Action executed correctly None
400 Bad Request Request input is not valid None
401 Unauthorized Unauthorized. AuthN and AuthZ validations have fail None
404 Not Found resource not found None
409 Conflict conflict if form is in some section None
410 Gone resource is not longer available None
500 Internal Server Error Not expected error None
default Default Error response ErrorsResponse

Endpoints

Documents

    Forms

      Sections

        Templates

          Templates Configuration

            Digital Sign Process

              Biometric Signature

                Simple Signature

                  Identification Agent

                    Sign Configuration

                      Identification OTP

                        Identification Agent Admin

                          Identification OTP Admin

                            Contracts

                              Scoring

                                Securize