---
updatedAt: 2025-02-13T22:01:22.000Z
agentTools:
  projectIndex: https://docs.delorean-ai.com/llms.txt
---

# Create Onboarding

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "Delorean API",
    "version": "1.1.0"
  },
  "servers": [
    {
      "url": "https://inference.api-stg.delorean-ai.com"
    }
  ],
  "paths": {
    "/api/v1/fraud/onboarding/": {
      "post": {
        "tags": [
          "Fraud Prevention"
        ],
        "summary": "Create Onboarding",
        "operationId": "create_onboarding_api_v1_fraud_onboarding__post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateOnboarding"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OnboardingProcessDataResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Address": {
        "properties": {
          "zip_code": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Zip Code",
            "example": "55400-270"
          },
          "city": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "City",
            "example": "rio de janeiro"
          },
          "street_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Street Name",
            "example": "avenida copacabana"
          },
          "street_number": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Street Number",
            "example": "154-A"
          },
          "complement": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Complement",
            "example": "behind shopping center"
          },
          "state": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "State",
            "example": "rio de janeiro"
          },
          "country": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Country",
            "description": "ISO 3166 alpha-2 Code.",
            "example": "BR"
          }
        },
        "type": "object",
        "title": "Address"
      },
      "BaseRuleDTO": {
        "properties": {
          "id": {
            "type": "integer",
            "title": "Id",
            "description": "Id of the rule.",
            "example": 15
          },
          "name": {
            "type": "string",
            "title": "Name",
            "example": "block all transactions from mobile."
          },
          "risk": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "LOW",
                  "MEDIUM",
                  "HIGH",
                  "VERY_HIGH"
                ]
              },
              {
                "type": "null"
              }
            ],
            "title": "Risk"
          }
        },
        "type": "object",
        "required": [
          "id",
          "name",
          "risk"
        ],
        "title": "Rule"
      },
      "CreateOnboarding": {
        "properties": {
          "customer": {
            "allOf": [
              {
                "$ref": "#/components/schemas/TransactionHolderWithId"
              }
            ],
            "description": "Informations about the customer."
          },
          "extra_data": {
            "anyOf": [
              {
                "additionalProperties": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "type": "number"
                    },
                    {
                      "type": "integer"
                    },
                    {
                      "type": "boolean"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Extra Data",
            "description": "This is a flat object, that is, no nested structures like lists and objects are allowed inside this object. Only primitive types are allowed, as seen in the example. If the model was trained with data that goes beyond our base layout, you can include these extra fields here. And even if the current model doesn't have this extra information yet, you can add it here to use in the future as data to new models. You can anonymize these field names and values, our models won't care about the actual value. Just ensure there will be field-wise consistency, not mixing types.",
            "example": {
              "custom_field_1": "value of custom field",
              "custom_field_2": 10.53,
              "custom_field_3": false
            }
          }
        },
        "type": "object",
        "required": [
          "customer"
        ],
        "title": "CreateOnboarding"
      },
      "DocType": {
        "type": "string",
        "enum": [
          "cpf",
          "cnpj",
          "passport"
        ],
        "title": "DocType"
      },
      "EnrichmentDType": {
        "type": "string",
        "enum": [
          "int",
          "float",
          "string",
          "bool",
          "list_string"
        ],
        "title": "EnrichmentDType"
      },
      "EnrichmentRuleDTO": {
        "properties": {
          "id": {
            "type": "integer",
            "title": "Id",
            "description": "Id of the rule.",
            "example": 15
          },
          "name": {
            "type": "string",
            "title": "Name",
            "example": "block all transactions from mobile."
          },
          "value": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Value"
          },
          "dtype": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/EnrichmentDType"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "type": "object",
        "required": [
          "id",
          "name"
        ],
        "title": "EnrichmentRule"
      },
      "HTTPValidationError": {
        "properties": {
          "detail": {
            "items": {
              "$ref": "#/components/schemas/ValidationError"
            },
            "type": "array",
            "title": "Detail"
          }
        },
        "type": "object",
        "title": "HTTPValidationError"
      },
      "Holder": {
        "properties": {
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name",
            "example": "Robin Williams"
          },
          "email": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Email",
            "example": "example@gmail.com"
          },
          "datetime_account_create": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ],
            "title": "Datetime Account Create",
            "description": "Datetime in ISO 8601 format (yyyy-MM-dd'T'HH:mm:ss.SSSXXX) of the start of the input filling.",
            "example": "2015-03-21T11:07:22.956087"
          },
          "phone_number": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Phone Number",
            "description": "Preference for E.164 standard, but any format is valid.",
            "example": "+5514912345678"
          },
          "birthdate": {
            "anyOf": [
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Birthdate",
            "description": "Date of birth in ISO 8601 date format (YYYY-MM-DD)",
            "example": "1980-03-16"
          },
          "doc_type": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/DocType"
              },
              {
                "type": "null"
              }
            ],
            "example": "cpf"
          },
          "doc": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Doc",
            "example": "12345678900"
          },
          "address": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/Address"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "type": "object",
        "title": "Holder"
      },
      "OnboardingProcessDataResponse": {
        "properties": {
          "id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "score": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Score"
          },
          "doc_status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Doc Status"
          },
          "risk": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Risk"
          },
          "rules_triggered": {
            "items": {
              "anyOf": [
                {
                  "$ref": "#/components/schemas/BaseRuleDTO"
                },
                {
                  "$ref": "#/components/schemas/EnrichmentRuleDTO"
                }
              ]
            },
            "type": "array",
            "title": "Rules Triggered"
          },
          "in_request_milliseconds": {
            "type": "number",
            "title": "In Request Milliseconds"
          },
          "timings": {
            "anyOf": [
              {
                "additionalProperties": {
                  "type": "number"
                },
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Timings"
          }
        },
        "type": "object",
        "required": [
          "rules_triggered",
          "in_request_milliseconds"
        ],
        "title": "OnboardingProcessDataResponse"
      },
      "PixKeyType": {
        "type": "string",
        "enum": [
          "CPF",
          "CNPJ",
          "EMAIL",
          "PHONE",
          "RANDOM"
        ],
        "title": "PixKeyType"
      },
      "TransactionAccount": {
        "properties": {
          "account_type": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "CHECKING_ACCOUNT",
                  "SAVINGS_ACCOUNT"
                ]
              },
              {
                "type": "null"
              }
            ],
            "title": "Account Type",
            "example": "CHECKING_ACCOUNT"
          },
          "institution_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Institution Name",
            "example": "Bank etc..."
          },
          "bank_code": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Bank Code",
            "description": "Bank code identifier.",
            "example": "001"
          },
          "branch_code": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Branch Code",
            "description": "Bank branch code identifier.",
            "example": "1234"
          },
          "branch_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Branch Name",
            "description": "Bank branch name identifier.",
            "example": "Branch 1234"
          },
          "account_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Account Id",
            "description": "Id that the client use, also know as account number.",
            "example": "12345678"
          },
          "country": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Country",
            "description": "ISO 3166 alpha-2 Code.",
            "example": "BR"
          },
          "account_create_date": {
            "anyOf": [
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Account Create Date",
            "description": "Indicates the date of the current account opening",
            "example": "2023-12-15"
          },
          "account_last_update_date": {
            "anyOf": [
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Account Last Update Date",
            "description": "Indicates the last date of personal information update for the current account",
            "example": "2023-12-15"
          }
        },
        "type": "object",
        "title": "TransactionAccount"
      },
      "TransactionHolderWithId": {
        "properties": {
          "id": {
            "type": "string",
            "title": "Id",
            "description": "Id of the customer, if you use a integer based id, convert to string in request time so we can support all range of id's, like UUID.",
            "example": "4b425c1c-a9e8-4f7e-b7e7-4cc201c3f798"
          },
          "registration_data": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/Holder"
              },
              {
                "type": "null"
              }
            ]
          },
          "banking_data": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/TransactionAccount"
              },
              {
                "type": "null"
              }
            ]
          },
          "pix_key": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Pix Key",
            "example": [
              "008.632.554-70"
            ]
          },
          "pix_key_type": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/PixKeyType"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Pix Key Type",
            "example": [
              "CPF"
            ]
          }
        },
        "type": "object",
        "required": [
          "id"
        ],
        "title": "TransactionHolderWithId"
      },
      "ValidationError": {
        "properties": {
          "loc": {
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer"
                }
              ]
            },
            "type": "array",
            "title": "Location"
          },
          "msg": {
            "type": "string",
            "title": "Message"
          },
          "type": {
            "type": "string",
            "title": "Error Type"
          }
        },
        "type": "object",
        "required": [
          "loc",
          "msg",
          "type"
        ],
        "title": "ValidationError"
      }
    }
  },
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true
  }
}
```