Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

mati

Package Overview
Dependencies
Maintainers
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mati

Client library for mati.io

  • 2.0.6
  • PyPI
  • Socket score

Maintainers
3

mati-python

Build Status Coverage Status PyPI

Mati Python3.6+ client library

Install

pip install mati

Testing

make venv
source venv/bin/activate
make test

Create Verification

from mati import Client

client = Client('api_key', 'secret_key')
verification = client.verifications.create(
    'some_flow_id',
    company_id='some_id',
)

Upload documents

from mati.types import (
    PageType,
    UserValidationFile,
    ValidationInputType,
    ValidationType,
)

# Load documents
front = open('ine_front.jpg', 'rb')
back = open('ine_back.jpg', 'rb')
live = open('liveness.mp4', 'rb')

# Create document with metadata
user_validation_file = UserValidationFile(
    filename='ine_front.jpg',
    content=front,
    input_type=ValidationInputType.document_photo,
    validation_type=ValidationType.national_id,
    country='MX',
    group=0, #The group is important when create your metamap
)
user_validation_file_back = UserValidationFile(
    filename='ine_back.jpg',
    content=back,
    input_type=ValidationInputType.document_photo,
    validation_type=ValidationType.national_id,
    country='MX',
    page=PageType.back,
    group=0,
)
user_validation_live = UserValidationFile(
    filename='liveness.MOV',
    content=live,
    input_type=ValidationInputType.selfie_video,
    group=1,
)

# Send documentation for validation
resp = client.verifications.upload_validation_data(
    [
        user_validation_file,
        user_validation_file_back,
        user_validation_live,
    ],
    verification.identity,
)

Verification status

Retrieve the verification when its complete

verification = client.verifications.retrieve('verification_id')

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc