Skip to main content
POST
/
api
/
app-api
/
sip
/
platform
/
v2
/
file
/
upload
cURL
curl -X POST \
-H 'x-ti-app-id: 1234567890' \
-H 'x-ti-secret-code: 1234567890' \
-F 'file=@invoice.pdf'
-F 'file=@another.pdf'
'https://docflow.textin.com/api/app-api/sip/platform/v2/file/upload?workspace_id=1234567890&category=invoice&batch_number=202412190001'
{
  "code": 200,
  "msg": "<string>",
  "result": {
    "batch_number": 202412190001,
    "files": [
      {
        "id": 202412190001,
        "name": "invoice.pdf",
        "format": "pdf",
        "task_id": 1981692246135111700
      }
    ]
  }
}

Authorizations

x-ti-app-id
string
header
required
x-ti-secret-code
string
header
required

Query Parameters

workspace_id
string
required

Workspace ID

Example:

1234567890

category
string

File Category

Example:

"invoice"

batch_number
string

Batch Number. You can upload multiple times with the same batch number, and later retrieve processing results for multiple files in that batch using the batch number. If the value is empty, the system automatically generates a string up to 20 characters long.

Example:

202412190001

auto_verify_vat
boolean
default:false

Whether to automatically verify VAT invoice

split_flag
boolean
default:false

Whether to perform file splitting

crop_flag
boolean
default:false

Whether to perform multi-image cropping

target_process
enum<string>

Target processing type. Optional values: - classify: Classification - extract: Extraction

Available options:
classify,
extract
Example:

"classify"

parser_remove_watermark
integer
default:0

Remove watermark (0 no, 1 yes)

parser_crop_dewarp
integer
default:0

Crop and dewarp (0 no, 1 yes)

parser_apply_merge
integer
default:1

Merge cross-page paragraphs and tables (0 no, 1 yes)

parser_formula_level
integer
default:0

Formula recognition level (0 recognizes both display and inline formulas, 1 recognizes display formulas only, 2 recognizes no formulas)

parser_table_text_split_mode
integer
default:0

Split text blocks crossed by table lines (0 no, 1 yes)

Body

File upload request body

file
file

Response

200 - application/json

File upload successful

code
integer
required

Status code

Example:

200

msg
string
required

Status description

result
object