Business Card

Transform your contract management process with Extracta.ai’s cutting-edge document parsing capabilities. Our API facilitates the extraction of key information from contracts, empowering legal teams, procurement departments, and businesses to automate data extraction, thereby enhancing contract analysis and management efficiency. This page offers a specialized request body template for contract parsing, designed to streamline your integration with our service.

Why Extracta.ai for Contract Parsing?

  • Efficient Data Extraction: Automate the extraction of critical contract elements, such as parties involved, terms, conditions, and obligations.

  • High Accuracy and Intelligence: Utilize Extracta.ai’s advanced algorithms for high-precision data extraction.

  • Customizable and Scalable: Adapt the data extraction to suit specific business needs, scalable for organizations of any size.

Getting Started

Initiate the process of parsing contracts through Extracta.ai by making a POST request to our /createExtraction endpoint. Below, we provide a request body template tailored for contract parsing. This template is preconfigured with keys for standard contract elements, streamlining the extraction process.

Body Example for Business Card

JSON Body
{
    "extractionDetails": {
        "name": "Business Card - Extraction",
        "language": "English",
        "fields": [
            {
                "key": "name",
                "description": "Name of the person in the business card",
                "example": "Bardahan Alexandru"
            },
            {
                "key": "job_title",
                "description": "Job title of the person",
                "example": "CEO"
            },
            {
                "key": "company_name",
                "description": "Extract company name from card; if absent, deduce from email, website, or social domains.",
                "example": "Fastapp Development"
            },
            {
                "key": "address",
                "description": "Address of the company",
                "example": "Bucharest, Romania"
            },
            {
                "key": "phone_numbers",
                "type": "array",
                "items": {
                    "type": "string",
                    "example": "+40 755 852 411"
                }
            },
            {
                "key": "email_addresses",
                "type": "array",
                "items": {
                    "type": "string",
                    "example": "office@fastappgroup.com"
                }
            },
            {
                "key": "website_url",
                "description": "Website url of the company",
                "example": "https://fastappgroup.com"
            },
            {
                "key": "social_media_handles",
                "description": "Social media handles of the company",
                "type": "array",
                "items": {
                    "type": "object",
                    "properties": [
                        {
                            "key": "type",
                            "description": "Type of the social media handle",
                            "example": "facebook"
                        },
                        {
                            "key": "username",
                            "description": "Username of the social media handle",
                            "example": "fastappgroup"
                        }
                    ]
                }
            }
        ]
    }
}

How to Use This Template

  1. Generate an API Key: Sign up at https://app.extracta.ai and visit the /api page to create your API key.

  2. Execute the API Call: Employ the JSON template in a POST request to /createExtraction, incorporating your API key in the request header as a Bearer token for authentication.

  3. Process the Extracted Data: The API will respond with structured data extracted from the contract, ready for integration into your systems or workflows.

Code Example

const axios = require('axios');

/**
 * Initiates a new document extraction process with the provided details.
 * 
 * @param {string} token - The authorization token for API access.
 * @param {Object} extractionDetails - The details of the extraction to be created.
 * @returns {Promise<Object>} The promise that resolves to the API response with the new extraction ID.
 */
async function createExtraction(token, extractionDetails) {
    const url = "https://api.extracta.ai/api/v1/createExtraction";

    try {
        const response = await axios.post(url, {
            extractionDetails
        }, {
            headers: {
                'Content-Type': 'application/json',
                'Authorization': `Bearer ${token}`
            }
        });

        // Handling response
        return response.data; // Directly return the parsed JSON response
    } catch (error) {
        // Handling errors
        throw error.response ? error.response.data : new Error('An unknown error occurred');
    }
}

async function main() {
    const token = 'apiKey';
    const extractionDetails = {}; // the json body from the example

    try {
        const response = await createExtraction(token, extractionDetails);
        console.log("New Extraction Created:", response);
    } catch (error) {
        console.error("Failed to create new extraction:", error);
    }
}

main();

Conclusion

Leverage Extracta.ai to elevate your contract management processes, from faster data retrieval to more informed decision-making. Our API not only simplifies the extraction of crucial contract details but also integrates seamlessly into various CRM platforms like Zoho, Salesforce, and HubSpot, enhancing your workflow automation.

For comprehensive instructions on integrating our API and leveraging its full capabilities, please refer to our API Endpoints and 1. Create extraction pages.

Last updated