MBTI.ai

METAPHYSICS

API





This is the official REST API documentation for devil.ai to allow you to generate MBTI tests programatically and gather the results when complete to integrate into your own applications / services.

Note: Larger clients may use the API endpoint domain: PersonalityPolice.com instead.

API Endpoint:

https://api.devil.ai/v1/

Response encoding:

JSON

Notice: Every API request requires an API key which you can request from [email protected] free






Create test link

Generate a test link for your user to complete.

Method name:

new_test

Accepts GET parameters:

Example:

curl --request GET \
    --url 'https://api.devil.ai/v1/new_test?api_key=123-123-123'

Successful response:

{
    "meta": {
        "status_code": 200,
        "success": true,
        "docs_url": "https://docs.devil.ai/",
        "total_results": 2
    },
    "data": {
        "test_id": "e5c467b01c91e4a307593d583a1890426621e96e94b54384717297",
        "test_url": "https://devil.ai/api-personality-test/e5c467b01c91e4a307593d583a1890426621e96e94b54384717297"
    }
}






Check test result

Check if the test is done and get its results.

Method name:

check_test

Accepts GET parameters:

Example:

curl --request GET \
    --url 'https://api.devil.ai/v1/check_test?api_key=123-123-123&test_id=e5c467b01c91e4a307593d583a1890426621e96e94b54384717297'

Successful response:

{
    "meta": {
        "status_code": 200,
        "success": true,
        "docs_url": "https://docs.devil.ai/",
        "total_results": 7
    },
    "data": {
        "prediction": "ESTJ",
        "predictions": {
            "ESTJ": 3,
            "INTP": 2,
            "ENTJ": 2,
            "ISTP": 2,
            "ENTP": 1,
            "ESFJ": 1,
            "INTJ": 1,
            "ISFP": 1,
            "ESTP": 1,
            "INFJ": 1,
            "INFP": 1,
            "ISFJ": 0,
            "ESFP": 0,
            "ENFJ": 0,
            "ISTJ": 0,
            "ENFP": 0
        },
        "trait_order_conscious": {
            "hero": "ti",
            "parent": "si",
            "child": "ni",
            "inferior": "fi"
        },
        "trait_order_shadow": {
            "nemesis": "ne",
            "critic": "te",
            "trickster": "se",
            "demon": "fe"
        },
        "matches": [
            "Matching ESTJ second highest conscious trait.",
            "Matching ESTJ lowest conscious trait.",
            "Matching ESTJ lowest unconscious trait.",
            "Matching ESTP second highest unconscious trait.",
            "Matching ISTP high conscious trait.",
            "Matching ISTP second lowest conscious trait.",
            "Matching ISFP second lowest conscious trait.",
            "Matching ESFJ second highest conscious trait.",
            "Matching ENTP second highest unconscious trait.",
            "Matching INTP high conscious trait.",
            "Matching INTP second lowest unconscious trait.",
            "Matching ENTJ lowest conscious trait.",
            "Matching ENTJ lowest unconscious trait.",
            "Matching INTJ high unconscious trait.",
            "Matching INFJ high unconscious trait.",
            "Matching INFP second lowest unconscious trait."
        ],
        "test_id": "e5c467b01c91e4a307593d583a1890426621e96e94b54384717297",
        "result_date": "2024-04-18 23:37:43",
        "results_page": "https://devil.ai/r/e5c467b01c91e4a307593d583a1890426621e96e94b54384717297"
    }
}