This OpenAPI describes the API exposed by the contract.fit backend. ## Security ### Authentication All endpoints are protected: you need to make authenticated calls. There are 3 authentication mechanisms: - HTTP Basic (Username + Password) - JWT Token - API-Key By default you should have an account allowing you to bootstrap your tenant and create users and roles, using Basic Auth or after creating a Token - see */auth* endpoints. If you are missing credentials or permissions, please [contact us](https://contract.fit/contact-us). ### Authorization The security system is RBAC based: users must be granted scoped roles, allowing them to access resources. Each role grants a defined set of permissions, which can be restricted to a given inbox or document - see */roles* endpoints. ## Upload and Processing Below is a short description of common use cases of the API. ### Simple Upload The easiest and simplest way to get started is to use POST /documents : it will make a synchronous
//cfportal.contract-p.fit/api135 endpoints available
/authLogin and retrieve a JWT Token
/rolesGet all roles
/rolesCreate role
/usersGet all users
/usersCreate user
/tenant/formatsGet lists of format
/formatsCreate format
/inboxesGet list of inboxes
/inboxesCreate an inbox
/reportsGet all reports
/reportsCreate report
/projectsGet the list of projects
/projectsCreate a project
/users/meReturn info on the current user
/sso/login/auth/tokenCreate a new token
/documents/Upload a new document
/sso/config/sso/config/connectionsGet all Connections
/connectionsCreate connection
/rule_configGet all rule configs
/stats/usage/auth/api-keyGet all API-Key
/auth/api-keyCreate a new API Key
/auth/get_JWTCreate a new JWT Token
/about/version/integrations/Get all integrations
/integrations/Create integration
/auth/ephemeralCreate a new ephemeral token
/style/logo.pngGet the custom logo
/style/logo.pngUpload the custom logo
/roles/{role_id}Get role
/roles/{role_id}Update role
/roles/{role_id}Delete a role
/settings/reviewGet scoped review setting
/settings/reviewUpdate scoped review setting
/tenant/activate/users/{user_id}Get user
/users/{user_id}Update user
/users/{user_id}Delete a user
/documents/enrich/reports/generateGenerate report based on input
/stats/{inbox_id}Get inbox statistics
/style/custom.cssGet the custom CSS file
/style/custom.cssUpload the custom logo
/sampling_settingsGet all sampling settings
/stats/{scope}/stpGet the STP counts on documents, sections and fields in the given inbox
/auth/api-key/{key}Get details of an API-Key
/auth/api-key/{key}Edit an API-Key
/auth/api-key/{key}Delete an API Key
/inboxes/{inbox_id}Get Inbox attributes
/inboxes/{inbox_id}Update inbox
/inboxes/{inbox_id}Delete an inbox
/predictor_settingsGet all predictor settings
/settings/dashboardGet scoped dashboard setting
/settings/dashboardUpdate scoped dashboard setting
/threshold_settingsGet all thresholds settings
/about/release_notes/auth/reset_passwordReset the user password
/formats/{format_id}Get format attributes
/formats/{format_id}Update the format
/formats/{format_id}Delete the format
/reports/{report_id}Get report
/reports/{report_id}Update report
/reports/{report_id}Delete a report
/rule_config/{scope}Get scoped rule config
/rule_config/{scope}Update scoped rule config
/rule_config/{scope}Delete scoped rule config
/documents/{inbox_id}Upload a new doc to the inbox
/projects/{project_id}Get project attributes
/projects/{project_id}Update project
/projects/{project_id}Delete project
/formats/document_typesGet supported document_types
/stats/{scope}/accuracyGet the Accuracy counts on documents, sections and fields in the given inbox
/data_retention_settingsGet all data retention settings
/documents/custom_outputGenerate custom output for documents
/documents/{document_id}Get the document
/documents/{document_id}Delete the document
/stats/{inbox_id}/volume**Permission required:** view_statistics
/rule_config/rule_entity/Get the regexes that are generated by the rule
/users/me/change_passwordChange the current user password
/sampling_settings/{scope}Get scoped sampling settings
/sampling_settings/{scope}Update scoped sampling settings
/sampling_settings/{scope}Delete scoped sampling settings
/formats/{scope}/tag_fieldsGet tags values
/predictor_settings/{scope}Get scoped predictor settings
/predictor_settings/{scope}Update scoped predictor settings
/predictor_settings/{scope}Delete scoped predictor settings
/sso/config/{sso_config_id}Get integration attributes
/stats/{inbox_id}/blue_dotsGet the Blue Dots statistics for the inbox
/threshold_settings/{scope}Get the scoped thresholds settings
/threshold_settings/{scope}Update the scoped thresholds settings
/threshold_settings/{scope}Delete the thresholds settings
/connections/{connection_id}Get connection
/connections/{connection_id}Update connection
/connections/{connection_id}Delete a connection
/stats/{inbox_id}/processingGet processing runtime stats
/documents/query/{query_type}/documents/{document_id}/textGet the document text
/inboxes/{inbox_id}/documentsGet documents in the inbox
/inboxes/{inbox_id}/documentsDelete documents
/inboxes/{inbox_id}/paginatedGet paginated list of documents in the inbox
/inboxes/{inbox_id}/reprocessSchedule inbox reprocessing
/reports/{report_id}/generateGenerate report based on report id
/auth/api-key/inbox/{inbox_id}Get all API-Keys for this inbox
/auth/api-key/inbox/{inbox_id}Create a new API Key on inbox level
/integrations/{integration_id}Get integration attributes
/integrations/{integration_id}Update integration
/integrations/{integration_id}Delete an integration
/documents/{inbox_id}/copy_inboxCopy documents to another inbox
/documents/{inbox_id}/move_inboxMove documents to another inbox
/documents/file_query/{data_type}/documents/{document_id}/feedbackSubmit a feedback
/documents/{document_id}/workflowGet the document Workflow
/documents/{document_id}/reprocessSchedule document reprocessing
/documents/{document_id}/status_dataUpdate document status
/stats/{inbox_id}/evaluated_versionsGet the documents with evaluated versions
/data_retention_settings/{level}/{id}Get scoped data retention settings
/data_retention_settings/{level}/{id}Update scoped data retention settings
/data_retention_settings/{level}/{id}Delete scoped sampling settings
/documents/{document_id}/last_versionGet latest version
/inboxes/{inbox_id}/document_versions/stats/{inbox_id}/automation_blockersGet summary or details of automation blockers
/documents/{document_id}/custom_outputGet custom output formatted document
/documents/{document_id}/original_fileGet document original file
/rule_config/rule_entity/{document_id}Evaluate a rule on a document
/integrations/{integration_id}/activate/documents/{document_id}/compare_versions/documents/{document_id}/page/{page_range}/rule_config/where_to_search/{document_id}Get the text a where_to_search specification will generate
/documents/{document_id}/reverse/{page_range}/documents/{document_id}/process_table_annotationProcess a table-level annotation
/documents/{document_id}/page_thumbnail/{page_range}This OpenAPI describes the API exposed by the contract.fit backend. ## Security ### Authentication All endpoints are protected: you need to make authenticated calls. There are 3 authentication mechanisms: - HTTP Basic (Username + Password) - JWT Token - API-Key By default you should have an account allowing you to bootstrap your tenant and create users and roles, using Basic Auth or after creating a Token - see */auth* endpoints. If you are missing credentials or permissions, please [contact us](https://contract.fit/contact-us). ### Authorization The security system is RBAC based: users must be granted scoped roles, allowing them to access resources. Each role grants a defined set of permissions, which can be restricted to a given inbox or document - see */roles* endpoints. ## Upload and Processing Below is a short description of common use cases of the API. ### Simple Upload The easiest and simplest way to get started is to use POST /documents : it will make a synchronous
//cfportal.contract-p.fit/api135 endpoints available
/authLogin and retrieve a JWT Token
/rolesGet all roles
/rolesCreate role
/usersGet all users
/usersCreate user
/tenant/formatsGet lists of format
/formatsCreate format
/inboxesGet list of inboxes
/inboxesCreate an inbox
/reportsGet all reports
/reportsCreate report
/projectsGet the list of projects
/projectsCreate a project
/users/meReturn info on the current user
/sso/login/auth/tokenCreate a new token
/documents/Upload a new document
/sso/config/sso/config/connectionsGet all Connections
/connectionsCreate connection
/rule_configGet all rule configs
/stats/usage/auth/api-keyGet all API-Key
/auth/api-keyCreate a new API Key
/auth/get_JWTCreate a new JWT Token
/about/version/integrations/Get all integrations
/integrations/Create integration
/auth/ephemeralCreate a new ephemeral token
/style/logo.pngGet the custom logo
/style/logo.pngUpload the custom logo
/roles/{role_id}Get role
/roles/{role_id}Update role
/roles/{role_id}Delete a role
/settings/reviewGet scoped review setting
/settings/reviewUpdate scoped review setting
/tenant/activate/users/{user_id}Get user
/users/{user_id}Update user
/users/{user_id}Delete a user
/documents/enrich/reports/generateGenerate report based on input
/stats/{inbox_id}Get inbox statistics
/style/custom.cssGet the custom CSS file
/style/custom.cssUpload the custom logo
/sampling_settingsGet all sampling settings
/stats/{scope}/stpGet the STP counts on documents, sections and fields in the given inbox
/auth/api-key/{key}Get details of an API-Key
/auth/api-key/{key}Edit an API-Key
/auth/api-key/{key}Delete an API Key
/inboxes/{inbox_id}Get Inbox attributes
/inboxes/{inbox_id}Update inbox
/inboxes/{inbox_id}Delete an inbox
/predictor_settingsGet all predictor settings
/settings/dashboardGet scoped dashboard setting
/settings/dashboardUpdate scoped dashboard setting
/threshold_settingsGet all thresholds settings
/about/release_notes/auth/reset_passwordReset the user password
/formats/{format_id}Get format attributes
/formats/{format_id}Update the format
/formats/{format_id}Delete the format
/reports/{report_id}Get report
/reports/{report_id}Update report
/reports/{report_id}Delete a report
/rule_config/{scope}Get scoped rule config
/rule_config/{scope}Update scoped rule config
/rule_config/{scope}Delete scoped rule config
/documents/{inbox_id}Upload a new doc to the inbox
/projects/{project_id}Get project attributes
/projects/{project_id}Update project
/projects/{project_id}Delete project
/formats/document_typesGet supported document_types
/stats/{scope}/accuracyGet the Accuracy counts on documents, sections and fields in the given inbox
/data_retention_settingsGet all data retention settings
/documents/custom_outputGenerate custom output for documents
/documents/{document_id}Get the document
/documents/{document_id}Delete the document
/stats/{inbox_id}/volume**Permission required:** view_statistics
/rule_config/rule_entity/Get the regexes that are generated by the rule
/users/me/change_passwordChange the current user password
/sampling_settings/{scope}Get scoped sampling settings
/sampling_settings/{scope}Update scoped sampling settings
/sampling_settings/{scope}Delete scoped sampling settings
/formats/{scope}/tag_fieldsGet tags values
/predictor_settings/{scope}Get scoped predictor settings
/predictor_settings/{scope}Update scoped predictor settings
/predictor_settings/{scope}Delete scoped predictor settings
/sso/config/{sso_config_id}Get integration attributes
/stats/{inbox_id}/blue_dotsGet the Blue Dots statistics for the inbox
/threshold_settings/{scope}Get the scoped thresholds settings
/threshold_settings/{scope}Update the scoped thresholds settings
/threshold_settings/{scope}Delete the thresholds settings
/connections/{connection_id}Get connection
/connections/{connection_id}Update connection
/connections/{connection_id}Delete a connection
/stats/{inbox_id}/processingGet processing runtime stats
/documents/query/{query_type}/documents/{document_id}/textGet the document text
/inboxes/{inbox_id}/documentsGet documents in the inbox
/inboxes/{inbox_id}/documentsDelete documents
/inboxes/{inbox_id}/paginatedGet paginated list of documents in the inbox
/inboxes/{inbox_id}/reprocessSchedule inbox reprocessing
/reports/{report_id}/generateGenerate report based on report id
/auth/api-key/inbox/{inbox_id}Get all API-Keys for this inbox
/auth/api-key/inbox/{inbox_id}Create a new API Key on inbox level
/integrations/{integration_id}Get integration attributes
/integrations/{integration_id}Update integration
/integrations/{integration_id}Delete an integration
/documents/{inbox_id}/copy_inboxCopy documents to another inbox
/documents/{inbox_id}/move_inboxMove documents to another inbox
/documents/file_query/{data_type}/documents/{document_id}/feedbackSubmit a feedback
/documents/{document_id}/workflowGet the document Workflow
/documents/{document_id}/reprocessSchedule document reprocessing
/documents/{document_id}/status_dataUpdate document status
/stats/{inbox_id}/evaluated_versionsGet the documents with evaluated versions
/data_retention_settings/{level}/{id}Get scoped data retention settings
/data_retention_settings/{level}/{id}Update scoped data retention settings
/data_retention_settings/{level}/{id}Delete scoped sampling settings
/documents/{document_id}/last_versionGet latest version
/inboxes/{inbox_id}/document_versions/stats/{inbox_id}/automation_blockersGet summary or details of automation blockers
/documents/{document_id}/custom_outputGet custom output formatted document
/documents/{document_id}/original_fileGet document original file
/rule_config/rule_entity/{document_id}Evaluate a rule on a document
/integrations/{integration_id}/activate/documents/{document_id}/compare_versions/documents/{document_id}/page/{page_range}/rule_config/where_to_search/{document_id}Get the text a where_to_search specification will generate
/documents/{document_id}/reverse/{page_range}/documents/{document_id}/process_table_annotationProcess a table-level annotation
/documents/{document_id}/page_thumbnail/{page_range}