Superwise

AI model monitoring platform

docs.superwise.ai ↗
Version
1.0
OpenAPI
3.0.0
Endpoints
29
Schemas
66
Updated
3 days ago
Ai ai monitoring ml-ops
Use this API in your AI agent

Query structured spec data via REST or MCP. Get exactly what your agent needs.

Get API Key

Server URLs

https://api.sandbox-65ebc.chico.ai
http://api.sandbox-65ebc.chico.ai

Authentication

apiKey

Endpoints

Clear filters

Automl service 5 endpoints

GET /v1/automl/runs
operationId: AutoMlService_getAllAutomlRuns

Parameters

Name In Required Type Description
module-id header optional string Module ID

Responses

200 Ok
GET /v1/automl/runs
GET /v1/automl/runs/{run_id}
operationId: AutoMlService_getRunSummary

Parameters

Name In Required Type Description
run_id path required string Run ID

Responses

200 Ok
GET /v1/automl/runs/{run_id}
GET /v1/automl/runs/{run_id}/status
operationId: AutoMlService_getRunStatus

Parameters

Name In Required Type Description
run_id path required string Run ID

Responses

200 Ok
GET /v1/automl/runs/{run_id}/status
GET /v1/automl/runs/{run_id}/status_batch_scores
operationId: AutoMlService_getStatusBatchScores

Parameters

Name In Required Type Description
run_id path required string Run ID

Responses

200 Ok
GET /v1/automl/runs/{run_id}/status_batch_scores
GET /v1/automl/users
operationId: AutoMlService_getAvailableUsers

Parameters

Name In Required Type Description
module-id header optional string Module ID
page_number query optional integer Page number, starting at 1
page_size query optional integer Number of users scored in run per page. Between 1 and 10000. Defaults to 500

Responses

200 Ok
GET /v1/automl/users

Client 1 endpoints

GET /v1/client/{access_key_id}

Fetch a client by its access key ID

operationId: Client_getByAccessKeyId

Parameters

Name In Required Type Description
access_key_id path required string Access Key ID

Responses

200 Ok
401 Unauthorized
404 Client not found
GET /v1/client/{access_key_id}

Enriched transactions 7 endpoints

GET /v1/module/transaction-enrichment/statistics

Retrieves statistics about a transaction enrichment module. The payload includes the number of distinct users and number of transactions.

operationId: EnrichedTransactions_getStatistics

Parameters

Name In Required Type Description
module-id header required string Module ID

Responses

200 OK
GET /v1/module/transaction-enrichment/statistics
GET /v1/module/transaction-enrichment/users

List the users in a transaction enrichment module. Optionally, you can pass a `user_id_prefix` as a query parameter to filter users by a user ID prefix. Every user will contain their user ID, as well as their first and last transaction dates.

operationId: EnrichedTransactions_listUserTransactions

Parameters

Name In Required Type Description
module-id header required string Module ID
user_id_prefix query optional string Prefix used to filter user_id results (e.g.: prefix = '2'-> users = ['23456', '24562']).
page_number query optional integer Page number, starting at 1
page_size query optional integer Number of elements per page. Defaults to 100

Responses

200 OK
GET /v1/module/transaction-enrichment/users
GET /v1/user/{user_id}/cashflow/categories

Detailed percentages of inflow and outflow for each category. Lists all the top level categories and the discrimination under each top level category

operationId: EnrichedTransactions_getUserCashflowCategories

Parameters

Name In Required Type Description
user_id path required string User ID
module-id header required string Module ID
start_date query optional string Minimum transaction date to be included (e.g. '2020-09-18 10:00:00').
end_date query optional string Maximum transaction date to be included (e.g. '2020-09-18 10:00:00').
account_type query optional string Specifies if we must include only an specific account type. Can be 'CREDIT_CARD', 'DEBIT_CARD', 'SAVINGS', 'CHECKING', 'INVESTMENT', 'PENSION', or 'LOAN'.

Responses

200 OK
GET /v1/user/{user_id}/cashflow/categories
GET /v1/user/{user_id}/cashflow/history

Creates a cashflow timeline for a given user, aggregating all transactions in a given window. The period windows can be of 1 hour, day, week, month or year.

operationId: EnrichedTransactions_getUserCashflowHistory

Parameters

Name In Required Type Description
user_id path required string User ID
module-id header required string Module ID
start_date query optional string Minimum transaction date to be included (e.g. '2020-09-18 10:00:00').
end_date query optional string Maximum transaction date to be included (e.g. '2020-09-18 10:00:00').
aggregation query optional string How to aggregate the cashflows in periods. Can be 'HOUR', 'DAY', 'WEEK', 'MONTH', or 'YEAR'.
account_type query optional string Specifies if we must include only an specific account type. Can be 'CREDIT_CARD', 'DEBIT_CARD', 'SAVINGS', 'CHECKING', 'INVESTMENT', 'PENSION', or 'LOAN'.

Responses

200 OK
GET /v1/user/{user_id}/cashflow/history
GET /v1/user/{user_id}/cashflow/statistics

Get the cashflow statistics for a given user per account type. That includes inflow, outflow, and net cashflow for each account type.

operationId: EnrichedTransactions_getUserCashflowStatistics

Parameters

Name In Required Type Description
user_id path required string User ID
module-id header required string Module ID
start_date query optional string Minimum transaction date to be included (e.g. '2020-09-18 10:00:00').
end_date query optional string Maximum transaction date to be included (e.g. '2020-09-18 10:00:00').

Responses

200 OK
GET /v1/user/{user_id}/cashflow/statistics
GET /v1/user/{user_id}/transactions

Returns the enriched transaction history of a user

operationId: EnrichedTransactions_getUserHistory

Parameters

Name In Required Type Description
user_id path required string User ID
module-id header required string Module ID
page_number query optional integer Page number, starting at 1
page_size query optional integer Number of elements per page
start_date query optional string Minimum transaction date to be included (e.g. '2020-09-18 10:00:00').
end_date query optional string Maximum transaction date to be included (e.g. '2020-09-18 10:00:00').
flow_type query optional string The flow type from transactions to be returned, must be either 'inflow', or 'outflow'. Defaults to returning both.
min_amount query optional number The minimum amount from transactions to be returned.
max_amount query optional number The maximum amount from transactions to be returned.
account_type query optional string Specifies if we must include only an specific account type.
categories query optional array List of categories to filter. Accept only category codes present on our taxonomy.
search_name query optional string Search for a specific string in the transaction description.

Responses

200 OK
GET /v1/user/{user_id}/transactions
GET /v1/user/{user_id}/transactions/statistics

Get the number of transactions, average transaction value and median.

operationId: EnrichedTransactions_getUserStatistics

Parameters

Name In Required Type Description
user_id path required string User ID
module-id header required string Module ID
start_date query optional string Minimum transaction date to be included (e.g. '2020-09-18 10:00:00').
end_date query optional string Maximum transaction date to be included (e.g. '2020-09-18 10:00:00').
flow_type query optional string The flow type from transactions to be returned, must be either 'inflow', or 'outflow'. Defaults to returning both.
min_amount query optional number The minimum amount from transactions to be returned.
max_amount query optional number The maximum amount from transactions to be returned.
account_type query optional string Specifies if we must include only an specific account type.

Responses

200 OK
GET /v1/user/{user_id}/transactions/statistics

Health 1 endpoints

GET /v1/health

Check if the server is alive

operationId: Health_checkStatus

Responses

200 I'm alive!
GET /v1/health

Personas 4 endpoints

GET /v1/persona

Lists all existing personas. Personas are sorted by creation date, with the most recently created personas appearing first. By default, all personas are returned. However, you can specify the type of personas you want by passing specific facet types as a query parameter. (e.g. `GET /persona?facet_types=interest,demographic`) Optionally, you can paginate the results by specifying the `page_number` and `page_size` query parameters. If either `page_number` and `page_size` are not specified, all personas will be returned.

operationId: Personas_listExisting

Parameters

Name In Required Type Description
facet_types query optional string Comma-separated facet types to select. By default, all personas are returned. Valid facet types are: interest, demographic, pre_defined_persona, custom.
module-id header optional string Module ID
page_number query optional integer Page number, starting at 1
page_size query optional integer Number of personas per page, between 1 and 10000. Will return all personas if not specified.

Responses

200 A list of personas available in the database.
400 Will return a 400 (Bad Request) error if the module-id is not provided when required or the month is invalid.
404 Will return a 404 (Not Found) error if the provided facet type is invalid or if a specific persona wasn't found.
GET /v1/persona
GET /v1/persona/{persona_id}

Returns statistics and information about a persona definition. The response includes the original persona definition, its creation date, as well as statistics about the persona's score distribution (e.g. number of users, average score, score percentiles, etc.). You can also specify the minimum persona score threshold that a user must meet to be included in the response. You must provide a valid persona ID. Otherwise, a 404 (Not Found) error will be returned.

operationId: Personas_getPersonaStatistics

Parameters

Name In Required Type Description
persona_id path required string Persona ID
module-id header optional string Module ID
month query optional string Reference month for persona scores in `YYYY-MM` format. Defaults to current month.
persona_score_threshold query optional number Minimum user persona score threshold to count a user as belonging to a persona in the response.

Responses

200 Ok
400 Will return a 400 (Bad Request) error if the provided module ID or month is invalid.
404 Will return a 404 (Not Found) error if the persona with provided `persona_id` does not exist.
GET /v1/persona/{persona_id}
GET /v1/persona/{persona_id}/percentile_score

Returns the score associated with a given percentile for a persona id.

operationId: Personas_getPercentileScore

Parameters

Name In Required Type Description
persona_id path required string Persona ID
percentile query required number Target percentile. Defaults to 50th percentile (i.e.: the median)
module-id header optional string Module ID
month query optional string Reference month for persona scores in `YYYY-MM` format. Defaults to current month.

Responses

200 Ok
400 Will return a 400 (Bad Request) error if the provided module ID or month is invalid.
404 Will return a 404 (Not Found) error if the persona with provided `persona_id` does not exist.
GET /v1/persona/{persona_id}/percentile_score
GET /v1/users/{user_id}/personas

Returns a list of personas and their scores for a given user. Personas are sorted by their persona score, in descending order. You can also specify the minimum persona score threshold that a user must meet to be included in the response. Defaults to hyperplane's suggested threshold to determine if the user belongs to the persona.

operationId: Personas_listUserPersonas

Parameters

Name In Required Type Description
user_id path required string User ID
module-id header optional string Module ID
month query optional string Reference month for persona scores in `YYYY-MM` format.
persona_score_threshold query optional number Minimum user persona score threshold to be included in the response.

Responses

200 Ok
400 Will return a 400 (Bad Request) error if the provided module ID or month is invalid.
404 Will return a 404 (Not Found) error if the user with provided `user_id` does not exist.
GET /v1/users/{user_id}/personas

Statistics 1 endpoints

GET /v1/statistics/latest_month

Returns the latest month with valid data.

operationId: Statistics_getLatestMonthData

Responses

200 Ok
GET /v1/statistics/latest_month

Schemas

string AutoMlServiceGetRunStatusResponse
{
  "type": "string"
}
string AutoMlServiceGetStatusBatchScoresResponse
{
  "type": "string"
}
array EnrichedTransactionsGetUserCashflowStatisticsResponse
{
  "type": "array",
  "items": {
    "$ref": "#/components/schemas/models.AccountCashflowOverview"
  }
}
string HealthCheckStatusResponse
{
  "type": "string"
}
string PersonasDeleteCustomPersonaResponse
{
  "type": "string"
}
array PersonasGetFacetAttributesResponse
{
  "type": "array",
  "items": {
    "$ref": "#/components/schemas/models.UserPersonasResponse"
  }
}
string StatisticsGetLatestMonthDataResponse
{
  "type": "string"
}
object api.ErrResponse
{
  "type": "object",
  "properties": {
    "error": {
      "type": "string"
    }
  }
}
object models.AccountCashflowOverview
{
  "type": "object",
  "required": [
    "account_type",
    "inflow_amount",
    "net_cashflow_amount",
    "outflow_amount"
  ],
  "properties": {
    "account_type": {
      "type": "string",
      "description": "Account type"
    },
    "inflow_amount": {
      "type": "number",
      "description": "Inflow amount on the given window"
    },
    "outflow_amount": {
      "type": "number",
      "description": "Outflow amount on the given window"
    },
    "net_cashflow_amount": {
      "type": "number",
      "description": "Net cashflow amount on the given window"
    }
  },
  "description": "Cashflow details for a given account of a given user"
}
object models.AuthRequest
{
  "type": "object",
  "required": [
    "client_id",
    "client_secret"
  ],
  "properties": {
    "client_id": {
      "type": "string",
      "example": "4681f83e-a4e9-11ee-a506-0242ac120002"
    },
    "client_secret": {
      "type": "string",
      "example": "W5qNTpWIT81r5qE3wHrtwXBujKdmGAvx"
    }
  }
}
object models.AuthResponse
{
  "type": "object",
  "properties": {
    "api_key": {
      "type": "string",
      "example": "v2.local.V0bmLbcYzFAs4w0VLqdV-XBssuwRPIflBf94lhrUHu3Lcg18Qiwb4fPgqIc9pLqvhDYPQhTDho5sBCWV_ZwwJ4sKYEc0g5GKEn9BUA8d-KnIbHnLyYKuqMDZflzQSCUdhwnFAcDqAlIqqpENdDVf01IL4wyhyC2F3CLqLVnwWCCFLonLjwpi7eNztZJ4REYPellWBDq3jL-2td4fQmcUvhGXz0T7GBlg9jGtOrs47sbUWS_QHgd1esEjgYm823OdTAk5yjuWD7CKF8P7bqg66A.bnVsbA"
    }
  }
}
object models.AutoMLBatchScoresCreateResponse
{
  "type": "object",
  "required": [
    "path"
  ],
  "properties": {
    "path": {
      "type": "string",
      "description": "Path where parquet file with the batch scores will be written"
    }
  }
}
object models.AutoMLLookalikeCreateRequest
{
  "type": "object",
  "required": [
    "engagement_type",
    "positive_label_users"
  ],
  "properties": {
    "engagement_type": {
      "type": "string",
      "description": "Intended use case of this product, between MULTI_ENGAGE and SINGLE_ENGAGE"
    },
    "run_description": {
      "type": "string",
      "description": "Custom run description to attach to run"
    },
    "negative_label_users": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.LookalikeLabel"
      },
      "description": "List of negative users in lookalike model. Model will be trained to identify users dissimilar to these users. If None, negative users will be generated from data. List length must be either 0 or greater than 10."
    },
    "positive_label_users": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.LookalikeLabel"
      },
      "description": "List of positive users in lookalike model. Model will be trained to identify users similar to these users. This list must contain at least ten elements."
    }
  }
}
object models.AutoMLLookalikeCreateResponse
{
  "type": "object",
  "required": [
    "input_label_summary",
    "run_id"
  ],
  "properties": {
    "run_id": {
      "type": "string",
      "description": "RunID is the unique identifier for the AutoML run"
    },
    "run_description": {
      "type": "string",
      "description": "Description of the run"
    },
    "input_label_summary": {
      "$ref": "#/components/schemas/models.InputLabelSummary"
    }
  },
  "x-konfig-properties": {
    "input_label_summary": {
      "description": "Analysis of input labels detailing amounts of labels given, amounts of labels detected, monthly breakdowns of positive rates and counts, and a breakdown of weights by label value."
    }
  }
}
object models.AutoMLRunGetIdResponse
{
  "type": "object",
  "required": [
    "run_description",
    "run_id",
    "status",
    "timestamp"
  ],
  "properties": {
    "run_id": {
      "type": "string",
      "description": "RunID is the unique identifier for the AutoML run"
    },
    "status": {
      "type": "string",
      "description": "RunStatus is the status of the AutoML training run"
    },
    "timestamp": {
      "type": "string",
      "description": "Timestamp is the time when the training run began"
    },
    "run_metrics": {
      "$ref": "#/components/schemas/models.AutoMLRunMetrics"
    },
    "engagement_type": {
      "type": "string",
      "description": "Engagement type of this product run"
    },
    "run_description": {
      "type": "string",
      "description": "RunDescription is the description of the AutoML training run"
    },
    "input_label_summary": {
      "$ref": "#/components/schemas/models.InputLabelSummary"
    },
    "number_of_train_users": {
      "type": "integer",
      "description": "NumberOfTrainUsers is the number of users in model training"
    },
    "number_of_inference_users": {
      "type": "integer",
      "description": "NumberOfInferenceUsers is the number of users in model inference"
    }
  },
  "x-konfig-properties": {
    "run_metrics": {
      "description": "RunMetrics is the metrics of the AutoML training run"
    },
    "input_label_summary": {
      "description": "Analysis of input labels detailing amounts of labels given, amounts of labels detected, monthly breakdowns of positive rates and counts, and a breakdown of weights by label value."
    }
  }
}
object models.AutoMLRunMetrics
{
  "type": "object",
  "properties": {
    "test_ks": {
      "type": "number",
      "description": "KS of the test set"
    },
    "test_auc": {
      "type": "number",
      "description": "AUC of the test set"
    },
    "train_ks": {
      "type": "number",
      "description": "KS of the training set"
    },
    "train_auc": {
      "type": "number",
      "description": "AUC of the training set"
    },
    "label_positive_rate": {
      "type": "number",
      "description": "The percentage of users with positive label in the test set."
    },
    "positive_rate_by_decile": {
      "type": "object",
      "description": "The percentage of positive examples (examples with a positive label) in each of the ten equally-sized groups (deciles) of the test data when this data is sorted based on the model's predicted scores.",
      "additionalProperties": {
        "type": "number"
      }
    },
    "cumulative_positive_rate": {
      "type": "object",
      "description": "Cumulative positive rates at various thresholds, including ascending (lower to higher thresholds) and descending (higher to lower thresholds). It indicates how the proportion of positive instances within the total instances changes as the classification threshold is adjusted.",
      "additionalProperties": {
        "type": "object",
        "additionalProperties": {
          "type": "number"
        }
      }
    }
  }
}
object models.AutoMLRunSummary
{
  "type": "object",
  "required": [
    "run_description",
    "run_id",
    "status",
    "timestamp"
  ],
  "properties": {
    "run_id": {
      "type": "string",
      "description": "RunID is the unique identifier for the AutoML run"
    },
    "status": {
      "type": "string",
      "description": "RunStatus is the status of the AutoML training run"
    },
    "timestamp": {
      "type": "string",
      "description": "Timestamp is the time when the training run began"
    },
    "run_metrics": {
      "$ref": "#/components/schemas/models.AutoMLRunMetrics"
    },
    "engagement_type": {
      "type": "string",
      "description": "Engagement type of this product run"
    },
    "run_description": {
      "type": "string",
      "description": "RunDescription is the description of the AutoML training run"
    },
    "input_label_summary": {
      "$ref": "#/components/schemas/models.InputLabelSummary"
    },
    "number_of_train_users": {
      "type": "integer",
      "description": "NumberOfTrainUsers is the number of users in model training"
    },
    "number_of_inference_users": {
      "type": "integer",
      "description": "NumberOfInferenceUsers is the number of users in model inference"
    }
  },
  "x-konfig-properties": {
    "run_metrics": {
      "description": "RunMetrics is the metrics of the AutoML training run"
    },
    "input_label_summary": {
      "description": "Analysis of input labels detailing amounts of labels given, amounts of labels detected, monthly breakdowns of positive rates and counts, and a breakdown of weights by label value."
    }
  }
}
object models.AutoMLRunUsersGetRequest
{
  "type": "object",
  "properties": {
    "allow_users": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.UserMetadata"
      },
      "description": "List of users to return user scores for"
    },
    "block_users": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.UserMetadata"
      },
      "description": "List of users to omit from returned user scores"
    },
    "tag_filters": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.TagCategoricalAttributeFilter"
      },
      "description": "Categorical Filters on pf_type metadata"
    }
  }
}
object models.AutoMLRunUsersGetResponse
{
  "type": "object",
  "required": [
    "user_scores"
  ],
  "properties": {
    "user_scores": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.UserScore"
      },
      "description": "List of user scores"
    },
    "last_scored_date": {
      "type": "string",
      "description": "Date string of last inference in `YYYY-MM-DD hh:mm:ss` format"
    }
  }
}
object models.AutoMLRunsGetResponse
{
  "type": "object",
  "required": [
    "runs"
  ],
  "properties": {
    "runs": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.AutoMLRunSummary"
      },
      "description": "List of AutoML run summaries"
    }
  }
}
object models.AutoMLUsersGetResponse
{
  "type": "object",
  "required": [
    "user_list"
  ],
  "properties": {
    "user_list": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.UserMetadata"
      },
      "description": "List of users' metadata"
    }
  }
}
object models.BatchUserPersonasRequest
{
  "type": "object",
  "required": [
    "user_ids"
  ],
  "properties": {
    "user_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "All user ids we want to fetch personas for"
    }
  }
}
object models.CashflowWindowStatistics
{
  "type": "object",
  "properties": {
    "window_end": {
      "type": "string",
      "description": "End time of the given window"
    },
    "window_start": {
      "type": "string",
      "description": "Start time of the given window"
    },
    "inflow_amount": {
      "type": "number",
      "description": "Inflow amount on the given window"
    },
    "outflow_amount": {
      "type": "number",
      "description": "Outflow amount on the given window"
    }
  },
  "description": "Inflow and outflow for a given user in a given time window"
}
object models.CategoricalAttributeFilter
{
  "type": "object",
  "required": [
    "allowed_values",
    "blocked_values"
  ],
  "properties": {
    "allowed_values": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "example": [
        "['0002']"
      ],
      "description": "Allowed values"
    },
    "blocked_values": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Blocked values"
    }
  }
}
object models.CategorizeTransactionsRequest
{
  "type": "object",
  "properties": {
    "transactions": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.Transaction"
      },
      "description": "List of transactions to be categorized"
    }
  }
}
object models.CategorizeTransactionsResponse
{
  "type": "object",
  "properties": {
    "categorized_transactions": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.TransactionCategory"
      },
      "description": "Categorized transactions"
    }
  }
}
object models.CategoryCashflow
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "Human-friendly category name"
    },
    "amount": {
      "type": "number",
      "description": "Aggregate amount for the given category"
    },
    "percentage": {
      "type": "number",
      "description": "Absolute amount flow for the category"
    },
    "taxonomy_path": {
      "type": "string",
      "description": "Human-friendly category taxonomy path"
    }
  },
  "description": "Amount percentage for a given category, related to either the total inflow or outflow"
}
object models.CategoryMetadata
{
  "type": "object",
  "properties": {
    "score": {
      "type": "string",
      "description": "A float between 0 and 1 representing a confidence on the predicted category. The higher the number, the greater the confidence."
    },
    "category": {
      "type": "string",
      "description": "The category of the transaction represented by a unique identifier in the Hyperplane's Taxonomy."
    }
  }
}
object models.ClientResponse
{
  "type": "object",
  "properties": {
    "is_disabled": {
      "type": "boolean",
      "example": false
    },
    "access_key_id": {
      "type": "string",
      "example": "823e064a-4cb7-11ee-be56-0242ac120002"
    }
  }
}
object models.FacetWeightObject
{
  "type": "object",
  "required": [
    "name",
    "weight"
  ],
  "properties": {
    "name": {
      "type": "string",
      "example": "international_traveler",
      "description": "Name of the facet"
    },
    "weight": {
      "type": "number",
      "example": 0.5,
      "description": "Weight of the facet"
    }
  }
}
object models.InputLabelSummary
{
  "type": "object",
  "required": [
    "num_input_labels",
    "num_input_users",
    "num_matched_labels",
    "num_training_users"
  ],
  "properties": {
    "monthly_counts": {
      "type": "object",
      "description": "For each month (shown in YYYY-MM format), the number of labels given.",
      "additionalProperties": {
        "type": "integer"
      }
    },
    "num_input_users": {
      "type": "integer",
      "description": "Number of distinct users that were provided by the user"
    },
    "num_input_labels": {
      "type": "integer",
      "description": "Number of labels that were provided by the user."
    },
    "num_matched_labels": {
      "type": "integer",
      "description": "Number of data rows that will be used in training"
    },
    "num_training_users": {
      "type": "integer",
      "description": "Number of distinct users that will be used in training"
    },
    "label_weight_counts": {
      "type": "object",
      "description": "Counts of given labels, broken down by label and weight. The keys are stringified pairs of (label_value, weight_value).",
      "additionalProperties": {
        "type": "integer"
      }
    },
    "monthly_positive_rates": {
      "type": "object",
      "description": "For each month (shown in YYYY-MM format), what is the rate of positive labels given.",
      "additionalProperties": {
        "type": "number"
      }
    }
  }
}
object models.ListPersonasResponse
{
  "type": "object",
  "required": [
    "personas"
  ],
  "properties": {
    "personas": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.PersonaCreateResponse"
      }
    }
  },
  "description": "Response of users linked to a given persona"
}
object models.Location
{
  "type": "object",
  "properties": {
    "city": {
      "type": "string",
      "description": "City name"
    },
    "type": {
      "type": "string",
      "description": "Type of location (e.g., personal, home, business, ...)"
    },
    "state": {
      "type": "string",
      "description": "State name"
    },
    "country": {
      "type": "string",
      "description": "Country name"
    },
    "latitude": {
      "type": "number",
      "description": "Location latitude"
    },
    "city_code": {
      "type": "string",
      "description": "IBGE city code"
    },
    "longitude": {
      "type": "number",
      "description": "Location longitude"
    },
    "postal_code": {
      "type": "string",
      "description": "Postal code (i.e., CEP, e.g., '22620-171')"
    },
    "full_address": {
      "type": "string",
      "description": "Full address (e.g., Av. Lúcio Costa 1234, Copacabana, Rio de Janeiro, Brasil)"
    },
    "primary_address": {
      "type": "string",
      "description": "Primary address (e.g., Av. Lúcio Costa, 1234)"
    }
  },
  "description": "Location where the transaction happened"
}
object models.LookalikeLabel
{
  "type": "object",
  "required": [
    "user_id"
  ],
  "properties": {
    "user_id": {
      "type": "string",
      "description": "UserID is the unique identifier for the user"
    },
    "timestamp": {
      "type": "string",
      "description": "Timestamp to filter the features available to the model. Should reflect when the model is called: email sent date, loan initialized date, etc. If None, all user features will be used"
    }
  }
}
object models.MerchantInfo
{
  "type": "object",
  "properties": {
    "cnae": {
      "type": "string",
      "description": "Merchant CNAE"
    },
    "cnpj": {
      "type": "string",
      "description": "Merchant CNPJ"
    },
    "name": {
      "type": "string",
      "description": "Merchant name"
    },
    "category": {
      "type": "string",
      "description": "Merchant category"
    },
    "business_name": {
      "type": "string",
      "description": "Merchant business name"
    }
  },
  "description": "Inferred merchant info after transaction enrichment"
}
object models.NumericalAttributeFilter
{
  "type": "object",
  "required": [
    "max_value",
    "min_value"
  ],
  "properties": {
    "max_value": {
      "type": "number",
      "example": 100000,
      "description": "Max attribute value"
    },
    "min_value": {
      "type": "number",
      "example": 0,
      "description": "Min attribute value"
    }
  },
  "description": "Definition of a filter on an attribute of numerical type."
}
object models.PaginationMetadata
{
  "type": "object",
  "required": [
    "next_page",
    "page_size"
  ],
  "properties": {
    "next_page": {
      "type": "integer",
      "example": 2,
      "description": "Next page number"
    },
    "page_size": {
      "type": "integer",
      "example": 100,
      "description": "Number of elements per page"
    }
  }
}
object models.PercentileScore
{
  "type": "object",
  "properties": {
    "score": {
      "type": "number",
      "example": 0.5,
      "description": "Score calculated for the given percentile"
    },
    "percentile": {
      "type": "number",
      "example": 0.1,
      "description": "Percentile for which the score is being fetched"
    }
  },
  "description": "Percentile and associated score."
}
object models.PersonaCreateRequest
{
  "type": "object",
  "required": [
    "persona_name"
  ],
  "properties": {
    "locations": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Optional list of zip codes or city ids to filter users by. If left empty, no location-based filtering is done."
    },
    "persona_name": {
      "type": "string",
      "example": "Young Professional",
      "description": "A name for describing this persona. Used for easy human-friendly identification."
    },
    "company_facets": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.FacetWeightObject"
      },
      "description": "Optional list of behavioral facet component objects. Each object outlines how a user's likelihood\nto consume from a particular company's products and how much it contributes to the persona definition. If left\nempty, no company-based scoring is done. Company facets can be found by listing personas of facet type\n'company'. Facet name must be a valid company facet in the persona taxonomy."
    },
    "interest_facets": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.FacetWeightObject"
      },
      "description": "Optional list of interest facet component objects. Each object represents how much an interest\nweighs in the persona. If left empty, no interest-based scoring is done. Interests can be found\nby listing personas of facet type 'interest'. Facet name must be a valid interest in the persona taxonomy."
    },
    "demographic_facets": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.FacetWeightObject"
      },
      "description": "Optional list of interest facet component objects. Defines how much each demographic attribute\n(location, affluence, household composition, etc.)  weighs in the persona. If left empty, no demographic-based\nscoring is done. Demographic facets can be found by listing personas of facet type 'demographic'. Facet name\nmust be a valid demographic facet in the persona taxonomy."
    },
    "pre_defined_personas": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.FacetWeightObject"
      },
      "description": "Optional list of pre-defined persona facet component objects. Each object outlines how a pre-defined\npersona ('Car Owners' or 'International Travelers') contributes to the persona definition. If left\nempty, no predefined personas are incorporated into the persona definition. Pre-defined personas have\nbeen optimized for financial use cases and have been validated at scale. They can be found by listing\npersonas of facet type 'pre_defined_persona'. Facet name must be a valid pre-defined persona facet in\nthe persona taxonomy."
    }
  },
  "description": "Defines a persona. Stores various weighted facets including their interests, demographics, location, company affinity, as well as predefined personas."
}
object models.PersonaCreateResponse
{
  "type": "object",
  "required": [
    "creation_datetime",
    "persona_id",
    "persona_name"
  ],
  "properties": {
    "persona_id": {
      "type": "string",
      "example": "1",
      "description": "Unique identifier for the persona"
    },
    "persona_name": {
      "type": "string",
      "example": "Young Professional",
      "description": "Name of the persona"
    },
    "creation_datetime": {
      "type": "string",
      "example": "2020-01-01T00:00:00",
      "description": "Creation datetime of persona"
    }
  }
}
object models.PersonaDetailsResponse
{
  "type": "object",
  "required": [
    "creation_datetime",
    "definition",
    "persona_id",
    "persona_score_statistics"
  ],
  "properties": {
    "definition": {
      "$ref": "#/components/schemas/models.PersonaCreateRequest"
    },
    "persona_id": {
      "type": "string",
      "example": "1",
      "description": "Unique identifier for the persona"
    },
    "creation_datetime": {
      "type": "string",
      "example": "2020-01-01T00:00:00",
      "description": "Creation datetime of persona"
    },
    "persona_score_statistics": {
      "$ref": "#/components/schemas/models.PersonaScoreStatistics"
    }
  },
  "x-konfig-properties": {
    "definition": {
      "description": "The persona definition used to create this persona"
    },
    "persona_score_statistics": {
      "description": "Statistical attributes about the persona score distribution"
    }
  }
}
object models.PersonaScorePercentiles
{
  "type": "object",
  "properties": {
    "percentile_10": {
      "type": "number",
      "example": 0.1
    },
    "percentile_20": {
      "type": "number",
      "example": 0.2
    },
    "percentile_30": {
      "type": "number",
      "example": 0.3
    },
    "percentile_40": {
      "type": "number",
      "example": 0.4
    },
    "percentile_50": {
      "type": "number",
      "example": 0.5
    },
    "percentile_60": {
      "type": "number",
      "example": 0.6
    },
    "percentile_70": {
      "type": "number",
      "example": 0.7
    },
    "percentile_80": {
      "type": "number",
      "example": 0.8
    },
    "percentile_90": {
      "type": "number",
      "example": 0.9
    }
  },
  "description": "Percentile scores for users scored for a particular persona."
}
object models.PersonaScoreStatistics
{
  "type": "object",
  "required": [
    "maximum_user_score",
    "minimum_user_score",
    "persona_score_threshold",
    "score_average",
    "score_percentiles",
    "score_standard_deviation",
    "total_users_above_threshold",
    "total_users_with_non_zero_score"
  ],
  "properties": {
    "score_average": {
      "type": "number",
      "example": 0.5,
      "description": "Average score over all scored users in this persona"
    },
    "score_percentiles": {
      "$ref": "#/components/schemas/models.PersonaScorePercentiles"
    },
    "maximum_user_score": {
      "type": "number",
      "example": 0.5,
      "description": "Highest persona score assigned to a user for this persona"
    },
    "minimum_user_score": {
      "type": "number",
      "example": 0.5,
      "description": "Lowest persona score assigned to a user for this persona"
    },
    "persona_score_threshold": {
      "type": "number",
      "example": 0.5,
      "description": "Score threshold used to determine whether a user belongs to this persona"
    },
    "score_standard_deviation": {
      "type": "number",
      "example": 0.5,
      "description": "Standard deviation over all scored users in this persona"
    },
    "total_users_above_threshold": {
      "type": "integer",
      "example": 1000,
      "description": "Total number of users who meet or exceed the score threshold to be considered part of this persona."
    },
    "total_users_with_non_zero_score": {
      "type": "integer",
      "example": 1000,
      "description": "Total number of users who have received a score for this persona."
    }
  },
  "description": "Statistical attributes about the score distribution for a particular persona.",
  "x-konfig-properties": {
    "score_percentiles": {
      "description": "Percentile distribution of scores for users who have been assigned a score for this persona"
    }
  }
}
object models.PersonaUser
{
  "type": "object",
  "required": [
    "id"
  ],
  "properties": {
    "id": {
      "type": "string",
      "example": "1",
      "description": "Unique identifier for the user"
    },
    "score": {
      "type": "number",
      "example": 0.5,
      "description": "Relevance score of user in this persona. In range `[0,1]`"
    }
  },
  "description": "User associated with a given persona"
}
object models.PersonaUsersResponse
{
  "type": "object",
  "required": [
    "users"
  ],
  "properties": {
    "users": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.PersonaUser"
      },
      "description": "Top users belonging to this persona"
    }
  },
  "description": "Response of users linked to a given persona"
}
object models.PostPersonaUsersRequest
{
  "type": "object",
  "required": [
    "blocklist",
    "branch"
  ],
  "properties": {
    "branch": {
      "$ref": "#/components/schemas/models.CategoricalAttributeFilter"
    },
    "cbo_code": {
      "$ref": "#/components/schemas/models.CategoricalAttributeFilter"
    },
    "blocklist": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "example": [
        "['1234']"
      ],
      "description": "List of user ids to not be included in the response"
    },
    "job_title": {
      "$ref": "#/components/schemas/models.CategoricalAttributeFilter"
    },
    "birth_date": {
      "$ref": "#/components/schemas/models.TimestampAttributeFilter"
    },
    "declared_monthly_income": {
      "$ref": "#/components/schemas/models.NumericalAttributeFilter"
    }
  },
  "description": "Extra information for filtering users",
  "x-konfig-properties": {
    "branch": {
      "description": "Filter branch based on a list of allowed values"
    },
    "cbo_code": {
      "description": "Filter cbo code based on a list of allowed values"
    },
    "job_title": {
      "description": "Filter job title based on a list of allowed values"
    },
    "birth_date": {
      "description": "Filter birth date based on a date range"
    },
    "declared_monthly_income": {
      "description": "Filter declared monthly income based on a numeric range"
    }
  }
}
object models.TagCategoricalAttributeFilter
{
  "type": "object",
  "required": [
    "allowed_values",
    "blocked_values",
    "tag_name"
  ],
  "properties": {
    "tag_name": {
      "type": "string",
      "description": "Tag name"
    },
    "allowed_values": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "example": [
        "['0002']"
      ],
      "description": "Allowed values"
    },
    "blocked_values": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Blocked values"
    }
  }
}
object models.TimestampAttributeFilter
{
  "type": "object",
  "required": [
    "max_value",
    "min_value"
  ],
  "properties": {
    "max_value": {
      "type": "string",
      "example": "2020-01-01T00:00:00",
      "description": "Max attribute value"
    },
    "min_value": {
      "type": "string",
      "example": "2000-01-01T00:00:00",
      "description": "Min attribute value"
    }
  },
  "description": "Definition of a filter on an attribute of timestamp type."
}
object models.TopLevelCategoryCashflow
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "Human-friendly category name"
    },
    "amount": {
      "type": "number",
      "description": "Aggregate amount for the given category"
    },
    "categories": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.CategoryCashflow"
      },
      "description": "Detailed predicted categories under the top-level"
    },
    "percentage": {
      "type": "number",
      "description": "Absolute amount flow for the category"
    }
  },
  "description": "Amount percentage for a given top level category. As well as subcategories division"
}
object models.Transaction
{
  "type": "object",
  "properties": {
    "amount": {
      "type": "number",
      "description": "The monetary value of a transaction. This is always a positive value."
    },
    "bank_id": {
      "type": "string",
      "description": "The name of the bank that is originating the transaction. For credit cards, this is the issuing bank."
    },
    "user_id": {
      "type": "string",
      "description": "A unique identifier for the user within the bank or institution."
    },
    "currency": {
      "type": "string",
      "description": "Currency enum based on ISO 4217. Eg: BRL, USD, MXN."
    },
    "account_id": {
      "type": "string",
      "description": "A unique identifier for the account within the bank or institution."
    },
    "description": {
      "type": "string",
      "description": "The raw text description of the transaction (do not clean or transform this).\nIt usually includes some information about the payment method, processor,\nmerchant, and in cases of transfer might include CNPJ or other reference numbers.\nSome examples:\n   - Pag*Mariaivaneidede\n   - Ifd*Puro Acai Beira Ma\n   - TED BCO 1 AGE 4598  CTA 291412  - RETIRADA EM C/C"
    },
    "account_type": {
      "type": "string",
      "description": "One of the following: checking, saving, credit card or investment."
    },
    "location_city": {
      "type": "string",
      "description": "The city in which the transaction happened. e.g. São Paulo, Mexico City, San Francisco."
    },
    "location_state": {
      "type": "string",
      "description": "The state in which the transaction happened. Eg: SP, CA."
    },
    "transaction_id": {
      "type": "string",
      "description": "A unique identifier for each transaction to identify the transaction within your bank or institution."
    },
    "location_country": {
      "type": "string",
      "description": "The country in which the transaction happened in ISO 3166-1 alpha-3 format. e.g. BRA (for transaction in Brazil), ESP (for transaction in Spain)."
    },
    "transaction_flow": {
      "type": "string",
      "description": "One of the following options: outflow (for spending) or inflow (for earning)."
    },
    "transaction_datetime": {
      "type": "string",
      "description": "Time when the transaction was performed."
    },
    "transaction_metadata": {
      "$ref": "#/components/schemas/models.TransactionMetadata"
    }
  },
  "x-konfig-properties": {
    "transaction_metadata": {
      "description": "A map used to store additional context about a transaction that might be useful for cleaning and understanding."
    }
  }
}
object models.TransactionCategory
{
  "type": "object",
  "properties": {
    "amount": {
      "type": "number",
      "description": "The monetary value of a transaction. This is always a positive value."
    },
    "bank_id": {
      "type": "string",
      "description": "The name of the bank that is originating the transaction. For credit cards, this is the issuing bank."
    },
    "user_id": {
      "type": "string",
      "description": "A unique identifier for the user within the bank or institution."
    },
    "currency": {
      "type": "string",
      "description": "Currency enum based on ISO 4217. Eg: BRL, USD, MXN."
    },
    "account_id": {
      "type": "string",
      "description": "A unique identifier for the account within the bank or institution."
    },
    "description": {
      "type": "string",
      "description": "The raw text description of the transaction (do not clean or transform this).\nIt usually includes some information about the payment method, processor,\nmerchant, and in cases of transfer might include CNPJ or other reference numbers.\nSome examples:\n   - Pag*Mariaivaneidede\n   - Ifd*Puro Acai Beira Ma\n   - TED BCO 1 AGE 4598  CTA 291412  - RETIRADA EM C/C"
    },
    "account_type": {
      "type": "string",
      "description": "One of the following: checking, saving, credit card or investment."
    },
    "location_city": {
      "type": "string",
      "description": "The city in which the transaction happened. e.g. São Paulo, Mexico City, San Francisco."
    },
    "location_state": {
      "type": "string",
      "description": "The state in which the transaction happened. Eg: SP, CA."
    },
    "transaction_id": {
      "type": "string",
      "description": "A unique identifier for each transaction to identify the transaction within your bank or institution."
    },
    "location_country": {
      "type": "string",
      "description": "The country in which the transaction happened in ISO 3166-1 alpha-3 format. e.g. BRA (for transaction in Brazil), ESP (for transaction in Spain)."
    },
    "transaction_flow": {
      "type": "string",
      "description": "One of the following options: outflow (for spending) or inflow (for earning)."
    },
    "category_metadata": {
      "$ref": "#/components/schemas/models.CategoryMetadata"
    },
    "transaction_datetime": {
      "type": "string",
      "description": "Time when the transaction was performed."
    },
    "transaction_metadata": {
      "$ref": "#/components/schemas/models.TransactionMetadata"
    }
  },
  "x-konfig-properties": {
    "category_metadata": {
      "description": "Predicted category and the confidence of the prediction"
    },
    "transaction_metadata": {
      "description": "A map used to store additional context about a transaction that might be useful for cleaning and understanding."
    }
  }
}
object models.TransactionEnrichmentResponse
{
  "type": "object",
  "properties": {
    "date": {
      "type": "string",
      "description": "Date of transaction"
    },
    "amount": {
      "type": "number",
      "description": "Amount of transaction"
    },
    "category": {
      "type": "string",
      "description": "Category enum of transaction"
    },
    "currency": {
      "type": "string",
      "description": "Transaction currency"
    },
    "description": {
      "type": "string",
      "description": "Transaction description"
    },
    "category_name": {
      "type": "string",
      "description": "Category human-readable name of transaction"
    },
    "merchant_info": {
      "$ref": "#/components/schemas/models.MerchantInfo"
    },
    "transaction_id": {
      "type": "string",
      "description": "Unique transaction id"
    },
    "transfer_metadata": {
      "$ref": "#/components/schemas/models.TransferMetadata"
    },
    "transaction_status": {
      "type": "string",
      "description": "Transaction status"
    },
    "current_installment": {
      "type": "integer",
      "description": "Current installment. If 0, it is not an installment"
    },
    "transaction_location": {
      "$ref": "#/components/schemas/models.Location"
    },
    "installment_start_date": {
      "type": "string",
      "description": "First installment date, that is, the purchase date"
    },
    "number_of_installments": {
      "type": "integer",
      "description": "Number of installments"
    },
    "total_installed_amount": {
      "type": "number",
      "description": "Sum of amounts for all installments"
    }
  },
  "x-konfig-properties": {
    "merchant_info": {
      "description": "Contains metadata about the merchant, if available."
    },
    "transfer_metadata": {
      "description": "Contains metadata about the payment method, the sender, and the receiver."
    },
    "transaction_location": {
      "description": "Location where the transaction happened"
    }
  }
}
object models.TransactionEnrichmentStatisticsResponse
{
  "type": "object",
  "required": [
    "transaction_count",
    "user_reach"
  ],
  "properties": {
    "user_reach": {
      "type": "integer",
      "example": 1000,
      "description": "Number of distinct users in the module"
    },
    "transaction_count": {
      "type": "integer",
      "example": 10000,
      "description": "Number of transactions in the module"
    }
  },
  "description": "General statistics for a given transaction enrichment module"
}
object models.TransactionEnrichmentUser
{
  "type": "object",
  "required": [
    "first_transaction_date",
    "last_transaction_date",
    "user_id"
  ],
  "properties": {
    "user_id": {
      "type": "string",
      "example": "123456",
      "description": "Unique user identifier"
    },
    "last_transaction_date": {
      "type": "string",
      "example": "2020-01-01T00:00:00Z",
      "description": "Date for last transaction registered for a given user."
    },
    "first_transaction_date": {
      "type": "string",
      "example": "2020-01-01T00:00:00Z",
      "description": "Date for first transaction registered for a given user."
    }
  }
}
object models.TransactionEnrichmentUsersResponse
{
  "type": "object",
  "required": [
    "pagination_metadata",
    "users"
  ],
  "properties": {
    "users": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.TransactionEnrichmentUser"
      },
      "description": "List of users related to the transactions"
    },
    "pagination_metadata": {
      "$ref": "#/components/schemas/models.PaginationMetadata"
    }
  },
  "description": "Page of users of a given module",
  "x-konfig-properties": {
    "pagination_metadata": {
      "description": "Pagination metadata needed to know the next call"
    }
  }
}
object models.TransactionMetadata
{
  "type": "object",
  "properties": {
    "mcc": {
      "type": "integer",
      "description": "MCC code for the merchant."
    },
    "account_balance": {
      "type": "number",
      "description": "Current account balance after this transaction."
    },
    "location_latitude": {
      "type": "number",
      "description": "A number between [“-90.0”, “90.0”] indicating the latitude of the location where the transaction happened."
    },
    "location_longitude": {
      "type": "number",
      "description": "A number between [“-180.0”, “180.0”] indicating the longitude of the location where the transaction happened."
    },
    "transaction_status": {
      "type": "string",
      "description": "Example: “Approved”, “Pending”, “Rejected”, “Rejected - Fraud”, …"
    },
    "current_installment": {
      "type": "integer",
      "description": "What installment this payment corresponds to."
    },
    "transfer_sender_name": {
      "type": "string",
      "description": "The name of the entity sending the money. e.g. “João da Silva”, “Padaria São João”."
    },
    "number_of_installments": {
      "type": "integer",
      "description": "How many installments will this purchase be payed off in."
    },
    "transfer_receiver_name": {
      "type": "string",
      "description": "The name of the entity receiving the money. e.g. “João da Silva”, “Padaria São João”."
    },
    "transfer_payment_method": {
      "type": "string",
      "description": "The method used for the transfer. Eg: “DOC”, “TED”, “PIX”"
    },
    "transfer_reference_number": {
      "type": "string",
      "description": "A control number used to uniquely identify a transfer."
    },
    "transfer_sender_document_name": {
      "type": "string",
      "description": "The name of the document used by the sender to issue the transfer. e.g. “CPF”, “CNPJ”."
    },
    "transfer_receiver_document_name": {
      "type": "string",
      "description": "The name of the document that identifies the entity receiving the transfer. e.g. “CPF”, “CNPJ”."
    },
    "transfer_sender_document_number": {
      "type": "string",
      "description": "A document number identifying the sender of the transfer (e.g. CPF, CNPJ)."
    },
    "transfer_receiver_document_number": {
      "type": "string",
      "description": "A document number identifying the receiver of the transfer (e.g. CPF, CNPJ)."
    }
  }
}
object models.TransferMetadata
{
  "type": "object",
  "properties": {
    "reason": {
      "type": "string",
      "description": "Transfer inferred reason"
    },
    "sender": {
      "$ref": "#/components/schemas/models.TransferParty"
    },
    "receiver": {
      "$ref": "#/components/schemas/models.TransferParty"
    },
    "payment_method": {
      "type": "string",
      "description": "Transfer payment method"
    },
    "reference_number": {
      "type": "string",
      "description": "Transfer reference number"
    }
  },
  "description": "Metadata related to the money transfer and involved parties",
  "x-konfig-properties": {
    "sender": {
      "description": "Transfer party that sends the money"
    },
    "receiver": {
      "description": "Transfer party that receives the money"
    }
  }
}
object models.TransferParty
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "Party name"
    },
    "branch_number": {
      "type": "string",
      "description": "Party branch number"
    },
    "document_name": {
      "type": "string",
      "description": "Party document name"
    },
    "account_number": {
      "type": "string",
      "description": "Party account number"
    },
    "routing_number": {
      "type": "string",
      "description": "Party routing number"
    },
    "document_number": {
      "type": "string",
      "description": "Party document number"
    },
    "routing_number_ISPB": {
      "type": "string",
      "description": "Party ISPB routing number"
    }
  },
  "description": "Attributes related to the sender or receiver of a given transaction"
}
object models.UserCashflowHistoryResponse
{
  "type": "object",
  "required": [
    "user_id",
    "windows"
  ],
  "properties": {
    "user_id": {
      "type": "string",
      "example": "123456",
      "description": "User identifier"
    },
    "windows": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.CashflowWindowStatistics"
      },
      "description": "Windows with calculated flows"
    }
  },
  "description": "Historic of cashflows for a given user"
}
object models.UserCashflowPerCategoryResponse
{
  "type": "object",
  "properties": {
    "user_id": {
      "type": "string",
      "description": "User identifier"
    },
    "inflow_categories": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.TopLevelCategoryCashflow"
      },
      "description": "Inflow discriminated by category"
    },
    "outflow_categories": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.TopLevelCategoryCashflow"
      },
      "description": "Outflow discriminated by category"
    }
  }
}
object models.UserMetadata
{
  "type": "object",
  "required": [
    "user_id"
  ],
  "properties": {
    "user_id": {
      "type": "string",
      "description": "UserID is the unique identifier for the user"
    }
  }
}
object models.UserPersonaScore
{
  "type": "object",
  "required": [
    "persona_id",
    "persona_name"
  ],
  "properties": {
    "persona_id": {
      "type": "string",
      "example": "1",
      "description": "Unique identifier for the persona"
    },
    "persona_name": {
      "type": "string",
      "example": "Young Professional",
      "description": "Name of the persona"
    },
    "persona_score": {
      "type": "number",
      "example": 0.5,
      "description": "Relevance score of user in this persona. In range `[0,1]`"
    }
  },
  "description": "User associated with a given persona"
}
object models.UserPersonasResponse
{
  "type": "object",
  "required": [
    "persona_scores",
    "user_id"
  ],
  "properties": {
    "user_id": {
      "type": "string",
      "example": "1",
      "description": "Unique identifier for the user"
    },
    "persona_scores": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.UserPersonaScore"
      },
      "description": "Ranked list of personas for this user"
    }
  },
  "description": "Response of personas linked to a given user"
}
object models.UserScore
{
  "type": "object",
  "required": [
    "score",
    "user_id"
  ],
  "properties": {
    "score": {
      "type": "number",
      "description": "Model inference score for the user"
    },
    "user_id": {
      "type": "string",
      "description": "UserID is the unique identifier for the user"
    }
  }
}
object models.UserTransactionsResponse
{
  "type": "object",
  "required": [
    "enriched_transactions",
    "pagination_metadata",
    "user_id"
  ],
  "properties": {
    "user_id": {
      "type": "string",
      "example": "123456",
      "description": "User identifier"
    },
    "pagination_metadata": {
      "$ref": "#/components/schemas/models.PaginationMetadata"
    },
    "enriched_transactions": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/models.TransactionEnrichmentResponse"
      },
      "description": "List of enriched transactions"
    }
  },
  "description": "Historic of enriched transactions of a given user",
  "x-konfig-properties": {
    "pagination_metadata": {
      "description": "Pagination metadata needed to know the next call"
    }
  }
}
object models.UserTransactionsStatisticsResponse
{
  "type": "object",
  "required": [
    "transaction_count"
  ],
  "properties": {
    "transaction_count": {
      "type": "integer",
      "example": 100,
      "description": "Number of transactions"
    },
    "median_transaction_value": {
      "type": "number",
      "example": 100,
      "description": "Median transaction value"
    },
    "average_transaction_value": {
      "type": "number",
      "example": 100,
      "description": "Average transaction value"
    }
  },
  "description": "Transaction statistics for a given user"
}