---
updatedAt: 2026-11-11T12:27:56.000Z
agentTools:
  projectIndex: https://docs.qwist.com/llms.txt
---

# Get income report

Get the income report which was created earlier. The language of the categories can be customized by using the `Accept-Language` HTTP header.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "nrich API",
    "version": "2.10",
    "contact": {
      "name": "Qwist GmbH",
      "email": "partnersupport@qwist.com",
      "url": "https://qwist.com"
    },
    "description": "This is the reference for Qwist's nrich API"
  },
  "x-readme": {
    "samples-languages": [
      "json",
      "shell"
    ]
  },
  "servers": [
    {
      "url": "https://api.nrich.qwist.cloud",
      "description": "Staging environment"
    }
  ],
  "tags": [
    {
      "name": "Income Report"
    },
    {
      "name": "User Management"
    },
    {
      "name": "Risk Report"
    },
    {
      "name": "Aggregations"
    }
  ],
  "paths": {
    "/rest/risk-reports": {
      "post": {
        "summary": "Create risk report",
        "operationId": "createRiskReport",
        "description": "Create risk report directly via API (without using the widget). This endpoint is only  relevant for licensed partners with a direct API integration.",
        "tags": [
          "Risk Report"
        ],
        "security": [
          {
            "user_auth": []
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The person name that will be used for account verification (Financial Ident verification)",
                    "example": "John Doe"
                  },
                  "account_ids": {
                    "type": "array",
                    "description": "Restrict the risk report to given accounts (do not consider other accounts for the report)",
                    "items": {
                      "$ref": "#/paths/~1rest~1accounts~1{account-id}/get/parameters/0/schema"
                    }
                  },
                  "reporting_period": {
                    "type": "integer",
                    "default": 12,
                    "minimum": 4,
                    "description": "Number of months to the past for which to generate the risk report."
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Risk report",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string",
                      "format": "UUID",
                      "example": "ae441170-b726-460c-af3c-b76756de00e0",
                      "description": "Report id"
                    },
                    "period": {
                      "type": "number",
                      "example": 12,
                      "description": "Number of months for which the report was requested. Default value is 12 months"
                    },
                    "accounts": {
                      "type": "array",
                      "description": "Provides account-specific risk reports. The first entry in the list will be the main account, which is identified as the account associated with the primary income source, if such an account exists.",
                      "items": {
                        "type": "object",
                        "description": "Account risk report",
                        "properties": {
                          "name": {
                            "type": "string",
                            "example": "FlexiCash",
                            "description": "Name of the account."
                          },
                          "type": {
                            "$ref": "#/paths/~1onetime~1account-verification/post/requestBody/content/application~1json/schema/allOf/1/properties/account_types/items"
                          },
                          "owners": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "example": "Max Mustermann, Erika Mustermann"
                            },
                            "description": "List of names of all the account holders."
                          },
                          "iban": {
                            "$ref": "#/paths/~1uploads/post/requestBody/content/application~1json/schema/properties/accounts/items/properties/iban"
                          },
                          "currency": {
                            "$ref": "#/paths/~1rest~1loans~1{loan-id}/get/responses/200/content/application~1json/schema/properties/currency"
                          },
                          "is_jointly_managed": {
                            "type": "boolean",
                            "description": "Indicates that the account has been opened by two or more individuals or entities."
                          },
                          "is_main_account": {
                            "type": "boolean",
                            "description": "Indicates whether the account is a primary income source (primary income was detected on this account)"
                          },
                          "last_transaction_on": {
                            "$ref": "#/paths/~1auth~1users/get/parameters/2/schema",
                            "description": "Latest transaction date"
                          },
                          "balance": {
                            "type": "object",
                            "description": "Balance report",
                            "properties": {
                              "days_in_overdraft": {
                                "type": "number",
                                "description": "Number of days the balance was negative"
                              },
                              "average": {
                                "type": "object",
                                "description": "Average balance",
                                "properties": {
                                  "one_month": {
                                    "type": "number",
                                    "format": "float",
                                    "example": 1234.56,
                                    "description": "Average balance over 1 month (30 days)"
                                  },
                                  "three_months": {
                                    "type": "number",
                                    "format": "float",
                                    "example": 234.56,
                                    "description": "Average balance over 3 months (90 days)"
                                  },
                                  "six_months": {
                                    "type": "number",
                                    "format": "float",
                                    "example": 562.67,
                                    "description": "Average balance over 6 months (180 days)"
                                  }
                                },
                                "required": [
                                  "one_month",
                                  "three_months",
                                  "six_months"
                                ]
                              }
                            },
                            "required": [
                              "days_in_overdraft",
                              "average"
                            ]
                          },
                          "verification_result": {
                            "type": "object",
                            "description": "Account verification result",
                            "properties": {
                              "provided": {
                                "$ref": "#/paths/~1rest~1account-verifications~1{account-verification-id}/get/responses/200/content/application~1json/schema/properties/provided"
                              },
                              "matched": {
                                "$ref": "#/paths/~1rest~1account-verifications~1{account-verification-id}/get/responses/200/content/application~1json/schema/properties/matched"
                              }
                            },
                            "required": [
                              "provided",
                              "matched"
                            ]
                          }
                        },
                        "required": [
                          "name",
                          "type",
                          "owners",
                          "iban",
                          "currency",
                          "is_jointly_managed",
                          "is_main_account",
                          "last_transaction_on",
                          "balance",
                          "verification_result"
                        ]
                      }
                    },
                    "income": {
                      "type": "object",
                      "description": "Income report",
                      "properties": {
                        "summary": {
                          "allOf": [
                            {
                              "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                            },
                            {
                              "type": "object",
                              "properties": {
                                "high": {
                                  "description": "Highest income amount"
                                },
                                "low": {
                                  "description": "Lowest income amount"
                                },
                                "average": {
                                  "description": "Average of the income on a monthly basis. Calculated as sum(expenses) / reporting_period (in months)"
                                },
                                "href": {
                                  "description": "A link to the list of the transactions matching the income stream"
                                }
                              }
                            }
                          ],
                          "required": [
                            "href",
                            "count",
                            "total",
                            "low",
                            "high",
                            "average"
                          ]
                        },
                        "regular": {
                          "type": "object",
                          "description": "Regular income aggregations (with a contract)",
                          "properties": {
                            "summary": {
                              "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/summary"
                            },
                            "streams": {
                              "type": "array",
                              "description": "Regular income summary by category (stream)",
                              "items": {
                                "allOf": [
                                  {
                                    "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "category": {
                                        "type": "object",
                                        "properties": {
                                          "id": {
                                            "$ref": "#/paths/~1rest~1categories/get/responses/200/content/application~1json/schema/items/properties/id"
                                          },
                                          "name": {
                                            "$ref": "#/paths/~1rest~1categories/get/responses/200/content/application~1json/schema/items/properties/name"
                                          }
                                        },
                                        "required": [
                                          "id",
                                          "name"
                                        ]
                                      },
                                      "first_booked_on": {
                                        "description": "The date of the first transaction for this stream",
                                        "$ref": "#/paths/~1auth~1users/get/parameters/2/schema"
                                      },
                                      "last_booked_on": {
                                        "description": "The date of the last transaction for this stream",
                                        "$ref": "#/paths/~1auth~1users/get/parameters/2/schema"
                                      },
                                      "payment_partner": {
                                        "$ref": "#/paths/~1rest~1payment-partners/get/responses/200/content/application~1json/schema/items/allOf/0"
                                      }
                                    },
                                    "required": [
                                      "category",
                                      "first_booked_on",
                                      "last_booked_on",
                                      "payment_partner"
                                    ]
                                  }
                                ]
                              }
                            }
                          }
                        },
                        "variable": {
                          "type": "object",
                          "description": "Variable income aggregations (without a contract)",
                          "properties": {
                            "summary": {
                              "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/summary"
                            },
                            "streams": {
                              "type": "array",
                              "description": "Variable income summary by category",
                              "items": {
                                "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/regular/properties/streams/items"
                              }
                            }
                          }
                        },
                        "primary": {
                          "allOf": [
                            {
                              "type": "object",
                              "description": "Primary income refers to the main source of regular income with the highest value. It is determined by grouping transactions according to their respective contracts and selecting the group with the largest total amount. For instance, if you receive a monthly salary and rental income, and your salary is greater than the rental amount, your salary will be considered your primary income source. We aggregate all transactions related to this primary income and provide a summary here.",
                              "properties": {
                                "recurrence": {
                                  "$ref": "#/paths/~1rest~1insurances~1{insurance-id}/get/responses/200/content/application~1json/schema/properties/payment_frequency",
                                  "description": "The recurrence of the primary income payments"
                                },
                                "stability": {
                                  "type": "number",
                                  "format": "float",
                                  "example": 0.5,
                                  "description": "Calculates the average number of transactions per month for the primary income category. This is determined by dividing the total count of primary income transactions by the  number of months for which transactions have been recorded (`primary income trx count / months`)."
                                }
                              },
                              "required": [
                                "recurrence",
                                "stability"
                              ]
                            },
                            {
                              "allOf": [
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/regular/properties/streams/items"
                                },
                                {
                                  "type": "object",
                                  "properties": {
                                    "payment_partner": {
                                      "description": "Payment partner associated with this expense / income stream",
                                      "$ref": "#/paths/~1rest~1payment-partners/get/responses/200/content/application~1json/schema/items/allOf/0"
                                    }
                                  }
                                }
                              ]
                            }
                          ]
                        },
                        "closeness": {
                          "type": "number",
                          "description": "Number of days since the last credit transaction",
                          "example": 10
                        },
                        "consumption_ratio": {
                          "type": "number",
                          "example": 0.5,
                          "description": "The consumption ratio of income measures the proportion of income spent over a specific period. It is calculated by dividing total expenses by total income for that period  (`expenses / income`). For example, a `consumption_ratio` of 0.5 indicates that half of the income was spent during the `reporting_period`."
                        },
                        "risk_indicators": {
                          "type": "object",
                          "description": "This section includes aggregated data on potentially risky income transactions, categorized  into sub-categories such as Chargeback, Gambling, Lottery, and Refund.",
                          "properties": {
                            "summary": {
                              "allOf": [
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/summary"
                                },
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/risk_indicators/properties/refund/allOf/1"
                                },
                                {
                                  "type": "object",
                                  "description": "Summary of all income risk indicators"
                                }
                              ]
                            },
                            "chargeback": {
                              "allOf": [
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                                },
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/risk_indicators/properties/refund/allOf/1"
                                },
                                {
                                  "type": "object",
                                  "description": "Aggregation including all kind of  <a target=\"_blank\" href=\"https://en.wikipedia.org/wiki/Chargeback\">chargeback-related</a>  transactions. This includes: - Chargeback due to exceeding credit limit activity - Chargeback due to deficiency cover activity - Chargeback due to double payment activity - Chargeback due to failed transactions activity - Chargeback due to objection activity"
                                }
                              ]
                            },
                            "gambling": {
                              "allOf": [
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                                },
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/risk_indicators/properties/refund/allOf/1"
                                },
                                {
                                  "type": "object",
                                  "description": "All gambling activity related transactions aggregated here"
                                }
                              ]
                            },
                            "lottery": {
                              "allOf": [
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                                },
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/risk_indicators/properties/refund/allOf/1"
                                },
                                {
                                  "type": "object",
                                  "description": "All lottery activity related transactions aggregated here"
                                }
                              ]
                            },
                            "refund": {
                              "allOf": [
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                                },
                                {
                                  "type": "object",
                                  "properties": {
                                    "ratio_to_expenses": {
                                      "type": "number",
                                      "example": 98,
                                      "description": "Ratio of the income to the total expenses in percent (`income * 100 / total expenses`)"
                                    }
                                  },
                                  "required": [
                                    "ratio_to_expenses"
                                  ]
                                },
                                {
                                  "type": "object",
                                  "description": "All refund activity related transactions aggregated here"
                                }
                              ]
                            }
                          },
                          "required": [
                            "summary",
                            "chargeback",
                            "gambling",
                            "lottery",
                            "refund"
                          ]
                        }
                      },
                      "required": [
                        "summary",
                        "regular",
                        "variable",
                        "primary",
                        "closeness",
                        "consumption_ratio",
                        "risk_indicators"
                      ]
                    },
                    "expenses": {
                      "type": "object",
                      "description": "Expenses report",
                      "properties": {
                        "summary": {
                          "allOf": [
                            {
                              "$ref": "#/paths/~1rest~1income-report/get/responses/200/content/application~1json/schema/properties/disposable_income/allOf/0"
                            },
                            {
                              "type": "object",
                              "properties": {
                                "count": {
                                  "type": "integer",
                                  "example": 14,
                                  "description": "Number of transactions in this income / expense stream"
                                },
                                "href": {
                                  "type": "string",
                                  "format": "uri",
                                  "example": "https://api.nrich.qwist.cloud/rest/transactions?categories=3,14&since=2020-01-01&until=2020-01-31",
                                  "description": "A link to the list of the transactions matching this income / expense stream"
                                }
                              },
                              "required": [
                                "count",
                                "href"
                              ]
                            }
                          ]
                        },
                        "regular": {
                          "type": "object",
                          "properties": {
                            "summary": {
                              "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                            },
                            "streams": {
                              "type": "array",
                              "description": "Regular expenses (Expenses for which a contract was detected)",
                              "items": {
                                "allOf": [
                                  {
                                    "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/regular/properties/streams/items"
                                  },
                                  {
                                    "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/risk_indicators/properties/atm/allOf/1"
                                  }
                                ]
                              }
                            }
                          }
                        },
                        "variable": {
                          "type": "object",
                          "properties": {
                            "summary": {
                              "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                            },
                            "streams": {
                              "type": "array",
                              "description": "Variable expenses (Irregular expenses - without contract)",
                              "items": {
                                "allOf": [
                                  {
                                    "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/regular/properties/streams/items"
                                  },
                                  {
                                    "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/risk_indicators/properties/atm/allOf/1"
                                  }
                                ]
                              }
                            }
                          }
                        },
                        "risk_indicators": {
                          "type": "object",
                          "description": "This section includes aggregated data on potentially risky transactions, categorized  into sub-categories such as ATM, Chargeback, Gambling, Debt Collection, and Loan.",
                          "properties": {
                            "summary": {
                              "allOf": [
                                {
                                  "allOf": [
                                    {
                                      "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                                    },
                                    {
                                      "type": "object",
                                      "properties": {
                                        "high": {
                                          "description": "The mathematically highest expense value, which represents the smallest absolute cost (e.g., -10.00 is higher than -50.00)."
                                        },
                                        "low": {
                                          "description": "The mathematically lowest expense value, which represents the largest absolute cost (e.g., -500.00 is lower than -100.00)."
                                        },
                                        "average": {
                                          "description": "Average of the expenses on a monthly basis. Calculated as sum(expenses) / reporting_period (in months)"
                                        },
                                        "href": {
                                          "description": "A link to the list of the transactions matching the expense stream"
                                        }
                                      }
                                    }
                                  ]
                                },
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/risk_indicators/properties/atm/allOf/1"
                                },
                                {
                                  "type": "object",
                                  "description": "Summary of all risk indicators"
                                }
                              ]
                            },
                            "atm": {
                              "allOf": [
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                                },
                                {
                                  "type": "object",
                                  "properties": {
                                    "ratio_to_income": {
                                      "type": "number",
                                      "example": 98,
                                      "description": "Ratio of the expenses to the total income in percent (`expenses * 100 / total income`)"
                                    }
                                  },
                                  "required": [
                                    "ratio_to_income"
                                  ]
                                },
                                {
                                  "type": "object",
                                  "description": "Summary of all ATM transactions booked over the reporting period"
                                }
                              ]
                            },
                            "gambling": {
                              "allOf": [
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                                },
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/risk_indicators/properties/atm/allOf/1"
                                },
                                {
                                  "type": "object",
                                  "description": "All gambling activity related transactions aggregated here"
                                }
                              ]
                            },
                            "debt_collection": {
                              "allOf": [
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                                },
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/risk_indicators/properties/atm/allOf/1"
                                },
                                {
                                  "type": "object",
                                  "description": "This section contains transaction aggregations related to <a target=\"_blank\" href=\"https://en.wikipedia.org/wiki/Debt_collection\">debt collection</>"
                                }
                              ]
                            },
                            "loan": {
                              "allOf": [
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                                },
                                {
                                  "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/risk_indicators/properties/atm/allOf/1"
                                },
                                {
                                  "type": "object",
                                  "description": "Here we aggregate transactions related to loans"
                                }
                              ]
                            }
                          }
                        }
                      }
                    }
                  },
                  "required": [
                    "id",
                    "period",
                    "accounts",
                    "income",
                    "expenses"
                  ]
                },
                "examples": {
                  "report": {
                    "summary": "Risk Report",
                    "value": {
                      "id": "be844e34-9c73-48dd-8c6b-ef7d67ec991c",
                      "period": 12,
                      "accounts": [
                        {
                          "name": "My Giro Account",
                          "type": "Giro account",
                          "owners": [
                            "Candice Hall"
                          ],
                          "iban": "DE36590100140000022375",
                          "currency": "EUR",
                          "is_jointly_managed": false,
                          "is_main_account": true,
                          "last_transaction_on": "2024-06-25",
                          "balance": {
                            "days_in_overdraft": 0,
                            "average": {
                              "one_month": -3419.92,
                              "three_months": -32654.87,
                              "six_months": -81322.03
                            }
                          },
                          "verification_result": {
                            "provided": {
                              "name": "Candice Hall"
                            },
                            "matched": {
                              "name": "Candice Hall",
                              "affinity": "VERY_HIGH"
                            }
                          }
                        }
                      ],
                      "income": {
                        "summary": {
                          "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=225,70,200,168,11,50,222,119,218,219,220,221,30&exclude_categories=&count=857&amount_gte=0",
                          "count": 857,
                          "total": 475945.4,
                          "low": 24432.24,
                          "high": 50242.94,
                          "average": 39662.12
                        },
                        "regular": {
                          "summary": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.1,C1071758383847374849.2,C1071758383847374849.3&categories=200,11&exclude_categories=&count=34&amount_gte=0",
                            "count": 34,
                            "total": 57700,
                            "low": 500,
                            "high": 5200,
                            "average": 4808.33
                          },
                          "streams": [
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.1,C1071758383847374849.2&categories=11&exclude_categories=&count=22&amount_gte=0",
                              "count": 22,
                              "total": 51700,
                              "low": 1200,
                              "high": 3500,
                              "average": 4308.33,
                              "category": {
                                "id": 11,
                                "name": "Income/Revenue"
                              },
                              "first_booked_on": "2024-06-03",
                              "last_booked_on": "2025-04-05"
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.3&categories=200&exclude_categories=&count=12&amount_gte=0",
                              "count": 12,
                              "total": 6000,
                              "low": 500,
                              "high": 500,
                              "average": 500,
                              "category": {
                                "id": 200,
                                "name": "Benefits"
                              },
                              "first_booked_on": "2024-05-17",
                              "last_booked_on": "2025-04-19"
                            }
                          ]
                        },
                        "variable": {
                          "summary": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=null&categories=50,11,119&exclude_categories=225,70,168,30,218,219,220,221,222&count=8&amount_gte=0",
                            "count": 8,
                            "total": 3330.21,
                            "low": 63.9,
                            "high": 907.63,
                            "average": 277.52
                          },
                          "streams": [
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=null&categories=11&exclude_categories=225,70,168,30,218,219,220,221,222&count=4&amount_gte=0",
                              "count": 4,
                              "total": 2134.39,
                              "low": 319.4,
                              "high": 722.5,
                              "average": 177.87,
                              "category": {
                                "id": 11,
                                "name": "Income/Revenue"
                              },
                              "first_booked_on": "2024-06-20",
                              "last_booked_on": "2025-04-25"
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=null&categories=50&exclude_categories=225,70,168,30,218,219,220,221,222&count=2&amount_gte=0",
                              "count": 2,
                              "total": 971.49,
                              "low": 63.9,
                              "high": 907.59,
                              "average": 80.96,
                              "category": {
                                "id": 50,
                                "name": "Credit"
                              },
                              "first_booked_on": "2024-12-12",
                              "last_booked_on": "2025-03-06"
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=null&categories=119&exclude_categories=225,70,168,30,218,219,220,221,222&count=2&amount_gte=0",
                              "count": 2,
                              "total": 224.33,
                              "low": 39.9,
                              "high": 184.43,
                              "average": 18.69,
                              "category": {
                                "id": 119,
                                "name": "Others"
                              },
                              "first_booked_on": "2024-09-19",
                              "last_booked_on": "2024-09-27"
                            }
                          ]
                        },
                        "primary": {
                          "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.1&categories=17&exclude_categories=&count=11&amount_gte=0",
                          "count": 11,
                          "total": 38500,
                          "low": 3500,
                          "high": 3500,
                          "average": 3208.33,
                          "category": {
                            "id": 17,
                            "name": "Wage/Salary"
                          },
                          "payment_partner": {
                            "id": "922a1f7f-b296-4aa9-8bb8-2c20671fb7dc",
                            "name": "Airfreu GmbH",
                            "website_url": "https://www.airfreu.de",
                            "logo_url": "https://airfreu.de/logo.png",
                            "latitude": -82.812838,
                            "longitude": -176.997153
                          },
                          "first_booked_on": "2024-06-04",
                          "last_booked_on": "2025-04-04",
                          "recurrence": "monthly",
                          "stability": 0.92
                        },
                        "risk_indicators": {
                          "summary": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=225,70,168,222,218,219,220,221,30&exclude_categories=&count=815&amount_gte=0",
                            "count": 815,
                            "total": 414915.19,
                            "low": 23932.24,
                            "high": 44633.75,
                            "average": 34576.27,
                            "ratio_to_expenses": 4.93
                          },
                          "chargeback": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=70,218,219,220,221,222&exclude_categories=&count=543&amount_gte=0",
                            "count": 543,
                            "total": 276941.5,
                            "low": 17390.9,
                            "high": 29096.86,
                            "average": 23078.46,
                            "ratio_to_expenses": 3.29
                          },
                          "gambling": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=30&exclude_categories=&count=87&amount_gte=0",
                            "count": 87,
                            "total": 46639.65,
                            "low": 2748.91,
                            "high": 6307.91,
                            "average": 3886.64,
                            "ratio_to_expenses": 0.55
                          },
                          "lottery": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=225&exclude_categories=&count=91&amount_gte=0",
                            "count": 91,
                            "total": 46598.41,
                            "low": 885.81,
                            "high": 6598.9,
                            "average": 3883.2,
                            "ratio_to_expenses": 0.55
                          },
                          "refund": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=168&exclude_categories=&count=94&amount_gte=0",
                            "count": 94,
                            "total": 44735.63,
                            "low": 1257.11,
                            "high": 8270.93,
                            "average": 3727.97,
                            "ratio_to_income": 0.53
                          }
                        },
                        "closeness": 18,
                        "consumption_ratio": 0.18
                      },
                      "expenses": {
                        "summary": {
                          "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=128,2,98,101,165,50,149,22,62,126,158,30&exclude_categories=&count=726&amount_lt=0",
                          "count": 726,
                          "total": -84123.91,
                          "low": -8630.66,
                          "high": -4851.28,
                          "average": -7010.33
                        },
                        "regular": {
                          "summary": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.4,C1071758383847374849.5,C1071758383847374849.6,C1071758383847374849.7,C1071758383847374849.8,C1071758383847374849.9,C1071758383847374849.10,C1071758383847374849.11,C1071758383847374849.12&categories=128,165,149,22,158,126&exclude_categories=&count=87&amount_lt=0",
                            "count": 87,
                            "total": -17340.4,
                            "low": -2042.76,
                            "high": -193.6,
                            "average": -1445.03
                          },
                          "streams": [
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.11,C1071758383847374849.7&categories=158&exclude_categories=&count=22&amount_lt=0",
                              "count": 22,
                              "total": -14303.08,
                              "low": -70.28,
                              "high": -1230,
                              "average": -1191.92,
                              "category": {
                                "id": 158,
                                "name": "Rent / Service charges"
                              },
                              "first_booked_on": "2024-06-04",
                              "last_booked_on": "2025-04-04",
                              "ratio_to_income": 0.23
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.12&categories=149&exclude_categories=&count=12&amount_lt=0",
                              "count": 12,
                              "total": -1324.2,
                              "low": -110.35,
                              "high": -110.35,
                              "average": -110.35,
                              "category": {
                                "id": 149,
                                "name": "Household"
                              },
                              "first_booked_on": "2024-05-16",
                              "last_booked_on": "2025-04-16",
                              "ratio_to_income": 0.02
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.9,C1071758383847374849.10&categories=165&exclude_categories=&count=24&amount_lt=0",
                              "count": 24,
                              "total": -683.76,
                              "low": -21.99,
                              "high": -34.99,
                              "average": -56.98,
                              "category": {
                                "id": 165,
                                "name": "Telecommunication"
                              },
                              "first_booked_on": "2024-05-16",
                              "last_booked_on": "2025-04-29",
                              "ratio_to_income": 0.01
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.5,C1071758383847374849.6&categories=128&exclude_categories=&count=13&amount_lt=0",
                              "count": 13,
                              "total": -653.16,
                              "low": -13.28,
                              "high": -493.8,
                              "average": -54.43,
                              "category": {
                                "id": 128,
                                "name": "Insurances"
                              },
                              "first_booked_on": "2024-05-26",
                              "last_booked_on": "2025-04-26",
                              "ratio_to_income": 0.01
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.4&categories=126&exclude_categories=&count=4&amount_lt=0",
                              "count": 4,
                              "total": -220.32,
                              "low": -55.08,
                              "high": -55.08,
                              "average": -18.36,
                              "category": {
                                "id": 126,
                                "name": "Taxes/Fees/Fines"
                              },
                              "first_booked_on": "2024-07-25",
                              "last_booked_on": "2025-04-25",
                              "ratio_to_income": 0
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=C1071758383847374849.8&categories=22&exclude_categories=&count=12&amount_lt=0",
                              "count": 12,
                              "total": -155.88,
                              "low": -12.99,
                              "high": -12.99,
                              "average": -12.99,
                              "category": {
                                "id": 22,
                                "name": "Leisure"
                              },
                              "first_booked_on": "2024-05-18",
                              "last_booked_on": "2025-04-20",
                              "ratio_to_income": 0
                            }
                          ]
                        },
                        "variable": {
                          "summary": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=null&categories=128,98,101,149,126&exclude_categories=&count=10&amount_lt=0",
                            "count": 10,
                            "total": -575.12,
                            "low": -136,
                            "high": -34.35,
                            "average": -47.93
                          },
                          "streams": [
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=null&categories=98&exclude_categories=&count=3&amount_lt=0",
                              "count": 3,
                              "total": -229.46,
                              "low": -64.58,
                              "high": -99.2,
                              "average": -19.12,
                              "category": {
                                "id": 98,
                                "name": "Shopping"
                              },
                              "first_booked_on": "2024-06-10",
                              "last_booked_on": "2024-12-07",
                              "ratio_to_income": 0
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=null&categories=149&exclude_categories=&count=2&amount_lt=0",
                              "count": 2,
                              "total": -128.1,
                              "low": -63.22,
                              "high": -64.88,
                              "average": -10.67,
                              "category": {
                                "id": 149,
                                "name": "Household"
                              },
                              "first_booked_on": "2024-05-18",
                              "last_booked_on": "2024-07-03",
                              "ratio_to_income": 0
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=null&categories=126&exclude_categories=&count=1&amount_lt=0",
                              "count": 1,
                              "total": -95.61,
                              "low": -95.61,
                              "high": -95.61,
                              "average": -7.97,
                              "category": {
                                "id": 126,
                                "name": "Taxes / Fees / Fines"
                              },
                              "first_booked_on": "2025-04-11",
                              "last_booked_on": "2025-04-11",
                              "ratio_to_income": 0
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=null&categories=101&exclude_categories=&count=2&amount_lt=0",
                              "count": 2,
                              "total": -63.39,
                              "low": -12.59,
                              "high": -50.8,
                              "average": -5.28,
                              "category": {
                                "id": 101,
                                "name": "Mobility"
                              },
                              "first_booked_on": "2024-12-01",
                              "last_booked_on": "2025-02-05",
                              "ratio_to_income": 0
                            },
                            {
                              "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=null&categories=128&exclude_categories=&count=2&amount_lt=0",
                              "count": 2,
                              "total": -58.56,
                              "low": -24.21,
                              "high": -34.35,
                              "average": -4.88,
                              "category": {
                                "id": 128,
                                "name": "Insurances"
                              },
                              "first_booked_on": "2024-09-20",
                              "last_booked_on": "2024-12-09",
                              "ratio_to_income": 0
                            }
                          ]
                        },
                        "risk_indicators": {
                          "summary": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=2,50,62,30&exclude_categories=&count=629&amount_lt=0",
                            "count": 629,
                            "total": -66208.39,
                            "low": -7136.78,
                            "high": -4497.22,
                            "average": -5517.37,
                            "ratio_to_income": 0.14
                          },
                          "atm": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=2&exclude_categories=&count=90&amount_lt=0",
                            "count": 90,
                            "total": -9642.87,
                            "low": -1162.5,
                            "high": -412.04,
                            "average": -803.57,
                            "ratio_to_income": 0.02
                          },
                          "debt_collection": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=62&exclude_categories=&count=87&amount_lt=0",
                            "count": 87,
                            "total": -9069.02,
                            "low": -1323.3,
                            "high": -519.52,
                            "average": -755.75,
                            "ratio_to_income": 0.02
                          },
                          "gambling": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=30&exclude_categories=&count=89&amount_lt=0",
                            "count": 89,
                            "total": -9486.32,
                            "low": -1378.09,
                            "high": -445.2,
                            "average": -790.53,
                            "ratio_to_income": 0.25
                          },
                          "loan": {
                            "href": "https://api.nrich.qwist.cloud?since=2024-05-13&until=2025-05-13&contracts=&categories=50&exclude_categories=&count=363&amount_lt=0",
                            "count": 363,
                            "total": -38010.18,
                            "low": -4333.98,
                            "high": -2419.89,
                            "average": -3167.51,
                            "ratio_to_income": 0.08
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/paths/~1rest~1user/put/responses/400"
          },
          "401": {
            "$ref": "#/paths/~1catalog/get/responses/401"
          }
        }
      }
    },
    "/rest/categories": {
      "get": {
        "summary": "Get categories",
        "operationId": "getCategories",
        "description": "Retrieve a list of categories associated to the transactions of this user. Each category entry also includes aggregated statistics of the referenced transactions like total amount, number of transactions, high and low values.",
        "tags": [
          "Aggregations"
        ],
        "parameters": [
          {
            "$ref": "#/paths/~1catalog/get/parameters/0"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/4"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/5"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/3"
          },
          {
            "in": "query",
            "name": "period",
            "schema": {
              "type": "string"
            },
            "description": "Only select transactions that were booked in the specified period. Available formats are:\n\n  * `YYYY` yearly (e.g. 2019)\n  * `YYYY-mm` monthly (e.g. 2019-12)\n  * `YYYY-Qq` quarterly (e.g. 2019-Q1): `Q` is the literal character \"Q\" and `q` refers to the annual quarter.\n  * `YYYY-Ww` weekly (e.g. 2019-W23): `W` is the literal character \"W\" and `w` refers to the ISO week number.\n  * `YYYY-mm-dd` (e.g. 2019-12-24)"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/0"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/1"
          },
          {
            "in": "query",
            "name": "sort",
            "schema": {
              "type": "string",
              "enum": [
                "asc",
                "desc"
              ],
              "default": "asc"
            },
            "description": "Determines the sort order of aggregation buckets. Sorting is performed based on the transactions total amount."
          },
          {
            "in": "query",
            "name": "amount_gte",
            "schema": {
              "type": "string"
            },
            "description": "Only select transactions with an amount **equal or greater** than this value."
          },
          {
            "in": "query",
            "name": "amount_lt",
            "schema": {
              "type": "string"
            },
            "description": "Only select transactions with an amount **less** than this value."
          }
        ],
        "security": [
          {
            "user_auth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Transaction aggregation.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "integer",
                        "description": "ID of the nrich standard category.",
                        "example": 123
                      },
                      "name": {
                        "type": "string",
                        "description": "Category name. The language depends on `Accept-Language` HTTP header provided in the request. Default is German.",
                        "example": "Online-Shopping"
                      },
                      "transactions": {
                        "type": "object",
                        "description": "Transaction statistics for this category in the requested period.",
                        "properties": {
                          "href": {
                            "type": "string",
                            "format": "uri",
                            "example": "https://api.nrich.qwist.cloud/rest/transactions?categories=3,14&since=2020-01-01&until=2020-01-31",
                            "description": "A link to the list of the transactions matching this category."
                          },
                          "count": {
                            "type": "integer",
                            "example": 14,
                            "description": "Number of transactions in this category."
                          },
                          "total": {
                            "type": "number",
                            "format": "float",
                            "example": 1234.56,
                            "description": "Total amount of transactions in this category."
                          },
                          "low": {
                            "type": "number",
                            "format": "float",
                            "example": -220.2,
                            "description": "Highest expense for this category."
                          },
                          "high": {
                            "type": "number",
                            "format": "float",
                            "example": 1400.5,
                            "description": "Highest deposit for this category."
                          }
                        },
                        "required": [
                          "href",
                          "count",
                          "total",
                          "low",
                          "high"
                        ]
                      },
                      "children": {
                        "description": "List of child categories of this category",
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "id": {
                              "$ref": "#/paths/~1rest~1categories/get/responses/200/content/application~1json/schema/items/properties/id"
                            },
                            "name": {
                              "$ref": "#/paths/~1rest~1categories/get/responses/200/content/application~1json/schema/items/properties/name"
                            },
                            "transactions": {
                              "$ref": "#/paths/~1rest~1categories/get/responses/200/content/application~1json/schema/items/properties/transactions"
                            }
                          }
                        }
                      }
                    },
                    "required": [
                      "id",
                      "name",
                      "transactions"
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/paths/~1rest~1user/put/responses/400"
          },
          "401": {
            "$ref": "#/paths/~1catalog/get/responses/401"
          }
        }
      }
    },
    "/rest/payment-partners": {
      "get": {
        "summary": "Get payment partners",
        "operationId": "getPaymentPartners",
        "description": "Retrieve a list of payment partners associated to the transactions of this user. Each entry includes aggregated statistics of the referenced transactions like total amount, number of transactions and average payment amount.",
        "tags": [
          "Aggregations"
        ],
        "parameters": [
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/4"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/5"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/3"
          },
          {
            "$ref": "#/paths/~1rest~1categories/get/parameters/4"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/0"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/1"
          },
          {
            "$ref": "#/paths/~1rest~1categories/get/parameters/7"
          },
          {
            "$ref": "#/paths/~1rest~1categories/get/parameters/8"
          },
          {
            "$ref": "#/paths/~1rest~1categories/get/parameters/9"
          }
        ],
        "security": [
          {
            "user_auth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Transaction aggregation.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "format": "UUID",
                            "example": "6702b891-b8e6-4892-8615-5440e39d3d0e",
                            "description": "Payment partner ID."
                          },
                          "name": {
                            "type": "string",
                            "description": "Name of payment partner.",
                            "example": "Qwist GmbH"
                          },
                          "website_url": {
                            "type": "string",
                            "format": "url",
                            "description": "The HTTP URL of the partners website",
                            "example": "https://qwist.com"
                          },
                          "logo_url": {
                            "type": "string",
                            "format": "url",
                            "description": "The HTTP URL of the partners logo",
                            "example": "https://qwist.com/wp-content/uploads/2024/04/qwist_logo.svg"
                          },
                          "latitude": {
                            "type": "number",
                            "format": "float",
                            "description": "Latitude of the partners physical location. If the partner is an online retailer i.e. Amazon - then the field is not provided",
                            "example": 52.508099
                          },
                          "longitude": {
                            "type": "number",
                            "format": "float",
                            "description": "Longitude of the partners physical location. If the partner is an online retailer i.e. Amazon - then the field is not provided",
                            "example": 13.329611
                          }
                        },
                        "required": [
                          "id",
                          "name"
                        ]
                      },
                      {
                        "type": "object",
                        "properties": {
                          "transactions": {
                            "type": "object",
                            "description": "Transaction statistics for this payment partner in the requested period.",
                            "properties": {
                              "href": {
                                "type": "string",
                                "format": "uri",
                                "example": "https://api.nrich.qwist.cloud/rest/transactions?payment_partners=6702b891-b8e6-4892-8615-5440e39d3d0e&since=2020-01-01&until=2020-01-31",
                                "description": "A link to a list of the transactions matching this payment partner."
                              },
                              "count": {
                                "type": "integer",
                                "example": 14,
                                "description": "Number of transactions transferred to this payment partner."
                              },
                              "total": {
                                "type": "number",
                                "format": "float",
                                "example": 279.86,
                                "description": "Total amount of transactions for this payment partner."
                              },
                              "average": {
                                "type": "number",
                                "format": "float",
                                "example": 19.99,
                                "description": "Average amount paid to this payment partner."
                              },
                              "last_booked_at": {
                                "$ref": "#/paths/~1auth~1users/get/parameters/2/schema",
                                "description": "Last booking date for this payment partner.",
                                "example": "2020-01-30"
                              }
                            },
                            "required": [
                              "href",
                              "count",
                              "total",
                              "average",
                              "last_booked_at"
                            ]
                          }
                        }
                      }
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/paths/~1rest~1user/put/responses/400"
          },
          "401": {
            "$ref": "#/paths/~1catalog/get/responses/401"
          }
        }
      }
    },
    "/auth/users": {
      "get": {
        "tags": [
          "User Management"
        ],
        "summary": "List users of client",
        "operationId": "listClientUsers",
        "security": [
          {
            "client_auth": []
          }
        ],
        "parameters": [
          {
            "in": "query",
            "name": "count",
            "schema": {
              "type": "integer",
              "default": 1000,
              "example": 100
            },
            "description": "Limit the number of returned items. In combination with the offset parameter this can be used to paginate the result list."
          },
          {
            "in": "query",
            "name": "offset",
            "schema": {
              "type": "integer",
              "default": 0,
              "example": 200
            },
            "description": "Skip this number of items in the response. In combination with the count parameter this can be used to paginate the result list."
          },
          {
            "in": "query",
            "name": "since",
            "schema": {
              "type": "string",
              "format": "date",
              "example": "2023-01-14"
            },
            "description": "Only entities with a corresponding date **equal or newer** to this date will be selected.",
            "example": "2020-02-01"
          },
          {
            "in": "query",
            "name": "until",
            "schema": {
              "$ref": "#/paths/~1auth~1users/get/parameters/2/schema"
            },
            "description": "Only entities with a corresponding date **equal or older** to this date will be selected.",
            "example": "2020-02-01"
          }
        ],
        "responses": {
          "200": {
            "description": "List of users associated with authenticated client.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "description": "List of users",
                  "properties": {
                    "users": {
                      "type": "array",
                      "items": {
                        "$ref": "#/paths/~1rest~1user/get/responses/200/content/application~1json/schema"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/paths/~1rest~1user/put/responses/400"
          },
          "401": {
            "$ref": "#/paths/~1catalog/get/responses/401"
          }
        }
      }
    },
    "/catalog": {
      "get": {
        "operationId": "listCatalogClientAuth",
        "summary": "List complete catalog (client_auth)",
        "description": "The real catalog contains thousands of entries, so expect the call to cause some traffic and delay. The example is only to highlight the data structure.\n*Note*: The client has to have the `accounts=rw` scope in order to retrieve the catalog.\n",
        "tags": [
          "Catalog"
        ],
        "security": [
          {
            "client_auth": []
          }
        ],
        "parameters": [
          {
            "name": "Accept-Language",
            "in": "header",
            "description": "Setting the Accept-Language to one of the available languages will return results in this language.",
            "schema": {
              "type": "string",
              "format": "ISO 639-1:2002"
            },
            "example": "de"
          },
          {
            "in": "query",
            "name": "country",
            "required": false,
            "description": "Two-letter country code. Show only resources within this country.  Country code is case-sensitive.",
            "schema": {
              "type": "string",
              "format": "ISO 3166-1 alpha-2",
              "example": "DE",
              "description": "Two-letter country code."
            }
          },
          {
            "in": "query",
            "name": "q",
            "required": false,
            "description": "Query for the entire catalog. Will match banks on domestic bank code, BIC, name or nrich ID. Will match services based on name or nrich ID.  Only exact matches are returned.",
            "schema": {
              "type": "string",
              "example": "10020030"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List of banks and services.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "banks": {
                      "type": "array",
                      "items": {
                        "$ref": "#/paths/~1rest~1catalog~1banks/get/responses/200/content/application~1json/schema/items"
                      },
                      "description": "List of supported banks"
                    },
                    "services": {
                      "type": "array",
                      "items": {
                        "$ref": "#/paths/~1rest~1catalog~1services/get/responses/200/content/application~1json/schema/items"
                      },
                      "description": "List of supported payment services"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "You are not authorized.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "object",
                      "properties": {
                        "code": {
                          "type": "integer",
                          "x-extensible-enum": [
                            1000,
                            1001,
                            1002,
                            1003,
                            1004,
                            1005,
                            1006,
                            1007,
                            1008,
                            1010,
                            1011,
                            1020,
                            1021,
                            10000,
                            10001,
                            10002,
                            10003,
                            10004,
                            10005,
                            10006,
                            10007,
                            10008,
                            10009,
                            10010,
                            10011,
                            10012,
                            10013,
                            10014,
                            10015,
                            10016,
                            10017,
                            20000,
                            20001,
                            20002,
                            20003,
                            20004,
                            20005,
                            20006,
                            20007,
                            30000,
                            30005,
                            30006,
                            40000,
                            40001,
                            40002,
                            40003
                          ],
                          "description": "| Code    | Group        | Description                                         |\n| ------- | ------------ | --------------------------------------------------- |\n| 1000    | client       | Invalid request                                     |\n| 1001    | client       | Entry already exists                                |\n| 1002    | client       | Entity not found                                    |\n| 1003    | client       | Unauthorized                                        |\n| 1004    | client       | Invalid client authorization                        |\n| 1005    | client       | Payment already processed                           |\n| 1006    | client       | Unprocessable entity                                |\n| 1007    | client       | Forbidden                                           |\n| 1008    | client       | Resource busy                                       |\n| 1010    | client       | User locked                                         |\n| 1011    | client       | Login credentials are incomplete or malformed       |\n| 1020    | client       | Maximum number of account synchronizations exceeded |\n| 1021    | client       | PSU IP is required                                  |\n| 10000   | user         | Login credentials are invalid                       |\n| 10001   | user         | PIN is invalid                                      |\n| 10002   | user         | Online access is blocked                            |\n| 10003   | user         | TAN scheme not activated                            |\n| 10004   | user         | TAN is invalid                                      |\n| 10005   | user         | No authorization for this account                   |\n| 10006   | user         | Transaction rejected                                |\n| 10007   | user         | PIN change necessary                                |\n| 10008   | user         | No authorization for this business transaction      |\n| 10009   | user         | HBCI activation necessary                           |\n| 10010   | user         | Account is blocked                                  |\n| 10011   | user         | Account no longer exists                            |\n| 10012   | user         | TAN scheme is blocked                               |\n| 10013   | user         | Status of transaction inconclusive                  |\n| 10014   | user         | Account not activated for online banking            |\n| 10015   | user         | Redundant submissions                               |\n| 10016   | user         | Invalid OTP                                         |\n| 10017   | user         | Invalid consent configuration                       |\n| 20000   | bank         | Processing at the bank not possible                 |\n| 20001   | bank         | Bank / account unknown                              |\n| 20002   | bank         | Transaction canceled                                |\n| 20003   | bank         | Maintenance                                         |\n| 20004   | bank         | Technical migration                                 |\n| 20005   | bank         | Transaction not possible                            |\n| 20006   | bank         | Login not possible                                  |\n| 20007   | bank         | Pop up                                              |\n| 30000   | general      | Processing at nrich not possible                    |\n| 30005   | general      | Task is expired                                     |\n| 30006   | general      | Service temporarily not available                   |\n| 40000   | general      | Bank not supported                                  |\n| 40001   | general      | Direct access upgrade                               |\n| 40002   | general      | Multi access upgrade                                |\n| 40003   | general      | Partial access upgrade                              |\n"
                        },
                        "data": {
                          "type": "object",
                          "description": "Additional data."
                        },
                        "description": {
                          "type": "string",
                          "description": "Human readable description of the error."
                        },
                        "group": {
                          "type": "string",
                          "description": "The source of the error.",
                          "enum": [
                            "client",
                            "user",
                            "bank",
                            "general"
                          ]
                        }
                      },
                      "required": [
                        "code",
                        "description",
                        "group"
                      ]
                    }
                  },
                  "required": [
                    "error"
                  ],
                  "example": {
                    "error": {
                      "code": 1000,
                      "data": {
                        "id": [
                          "Missing data for required field."
                        ]
                      },
                      "description": "Invalid query-string parameters.",
                      "group": "client"
                    }
                  }
                },
                "example": {
                  "error": {
                    "code": 1003,
                    "group": "client",
                    "data": {},
                    "description": "Unauthorized."
                  }
                }
              }
            }
          }
        }
      }
    },
    "/rest/income-report": {
      "get": {
        "summary": "Get and Generate Income Report",
        "operationId": "getAndGenerateIncomeReport",
        "description": "Get Income Report for an account or an access creating the report on the fly",
        "parameters": [
          {
            "$ref": "#/paths/~1catalog/get/parameters/0"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/5"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/4"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/0"
          },
          {
            "$ref": "#/paths/~1rest~1timeline/get/parameters/1"
          }
        ],
        "tags": [
          "Income Report"
        ],
        "security": [
          {
            "user_auth": []
          }
        ],
        "responses": {
          "200": {
            "description": "The income report generated as per request parameters",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "description": "The user's income report",
                  "properties": {
                    "id": {
                      "type": "string",
                      "format": "uuid",
                      "description": "ID of the report",
                      "example": "fc1dacd6-25c8-e7e2-f106-aaf2ea8b09f"
                    },
                    "period": {
                      "type": "integer",
                      "description": "The period in months for which the income report was requested"
                    },
                    "income": {
                      "description": "The income streams and their summaries",
                      "allOf": [
                        {
                          "$ref": "#/paths/~1rest~1income-report/get/responses/200/content/application~1json/schema/properties/regular_expenses/items"
                        },
                        {
                          "type": "object",
                          "properties": {
                            "primary": {
                              "description": "A primary income stream",
                              "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/primary/allOf/1"
                            }
                          }
                        }
                      ]
                    },
                    "regular_expenses": {
                      "type": "array",
                      "description": "Regular expenses, such as rent payments, monthly phone payments, quarterly radio tax payments",
                      "items": {
                        "type": "object",
                        "properties": {
                          "summary": {
                            "description": "A summary of an income/expense stream, such as low, high, average values",
                            "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/expenses/properties/summary"
                          },
                          "streams": {
                            "type": "array",
                            "description": "List of income/expense streams",
                            "items": {
                              "$ref": "#/paths/~1rest~1risk-reports/post/responses/200/content/application~1json/schema/properties/income/properties/regular/properties/streams/items"
                            }
                          }
                        },
                        "required": [
                          "summary",
                          "streams"
                        ]
                      }
                    },
                    "variable_expenses": {
                      "type": "array",
                      "description": "Variable expenses - all expenses that are not regular, such as grocery shopping, buying clothes",
                      "items": {
                        "$ref": "#/paths/~1rest~1income-report/get/responses/200/content/application~1json/schema/properties/regular_expenses/items"
                      }
                    },
                    "disposable_income": {
                      "description": "The amount left after deducting regular expenses from the total income.\nThe formula for calculating this would be total_income - regular_expenses",
                      "allOf": [
                        {
                          "type": "object",
                          "properties": {
                            "total": {
                              "type": "number",
                              "format": "float",
                              "example": 1234.56,
                              "description": "Total amount of transactions"
                            },
                            "low": {
                              "type": "number",
                              "format": "float",
                              "example": -220.2,
                              "description": "Highest expense / Lowest deposit"
                            },
                            "high": {
                              "type": "number",
                              "format": "float",
                              "example": 1400.5,
                              "description": "Lowest expense / Highest deposit"
                            },
                            "average": {
                              "type": "number",
                              "description": "The arithmetic average of the amounts",
                              "format": "float",
                              "example": 2123.25
                            }
                          },
                          "required": [
                            "total",
                            "low",
                            "high",
                            "average"
                          ]
                        },
                        {
                          "type": "object",
                          "properties": {
                            "ratio": {
                              "type": "number",
                              "format": "float",
                              "description": "The ratio of the disposable/discretionary income to the total income amount.\nExample: a total income amount of 1000 with a leftover of 500 yields a ratio of 0.5",
                              "example": 0.32
                            }
                          },
                          "required": [
                            "ratio"
                          ]
                        }
                      ]
                    },
                    "discretionary_income": {
                      "$ref": "#/paths/~1rest~1income-report/get/responses/200/content/application~1json/schema/properties/disposable_income",
                      "description": "The amount left after deducting variable expense from the disposable income.\nIt could be expressed as: total_income - (regular_expenses + variable_expenses)"
                    },
                    "created_at": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The time at which the report was generated."
                    }
                  },
                  "required": [
                    "id",
                    "period",
                    "income",
                    "regular_expenses",
                    "variable_expenses",
                    "disposable_income",
                    "discretionary_income",
                    "created_at"
                  ]
                }
              }
            }
          },
          "401": {
            "$ref": "#/paths/~1catalog/get/responses/401"
          }
        }
      }
    },
    "/rest/income-reports/{id}": {
      "get": {
        "summary": "Get income report",
        "operationId": "getIncomeReport",
        "description": "Get the income report which was created earlier. The language of the categories can be customized by using the `Accept-Language` HTTP header.",
        "tags": [
          "Income Report"
        ],
        "security": [
          {
            "user_auth": []
          }
        ],
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "ID of the report",
            "example": "fc1dacd6-25c8-e7e2-f106-aaf2ea8b09f"
          }
        ],
        "responses": {
          "200": {
            "$ref": "#/paths/~1rest~1income-report/get/responses/200"
          },
          "400": {
            "$ref": "#/paths/~1rest~1user/put/responses/400"
          },
          "401": {
            "$ref": "#/paths/~1catalog/get/responses/401"
          }
        }
      }
    },
    "/rest/user": {
      "put": {
        "summary": "Modify user",
        "operationId": "updateUser",
        "description": "Update details of the user associated with the access token used for authentication.",
        "tags": [
          "User Management"
        ],
        "security": [
          {
            "user_auth": []
          }
        ],
        "requestBody": {
          "description": "",
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "email": {
                    "type": "string",
                    "format": "email",
                    "example": "user@example.com",
                    "description": "E-mail address/nrich account username."
                  },
                  "language": {
                    "type": "string",
                    "format": "ISO 639-1:2002",
                    "example": "de",
                    "description": "Two-letter language code."
                  },
                  "full_name": {
                    "type": "string",
                    "example": "John Doe",
                    "description": "Full name of the nrich account user."
                  },
                  "new_password": {
                    "$ref": "#/paths/~1auth~1user/post/requestBody/content/application~1json/schema/properties/password",
                    "description": "New finX account password. If this field is set, then the field `password` must be set too."
                  },
                  "password": {
                    "$ref": "#/paths/~1auth~1user/post/requestBody/content/application~1json/schema/properties/password",
                    "description": "Current finX account password."
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "$ref": "#/paths/~1rest~1user/get/responses/200"
          },
          "400": {
            "description": "Bad request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/paths/~1catalog/get/responses/401/content/application~1json/schema"
                },
                "example": {
                  "error": {
                    "code": 1000,
                    "group": "client",
                    "data": {},
                    "description": "Bad request."
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/paths/~1catalog/get/responses/401"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "user_auth": {
        "type": "http",
        "description": "In order to access any information belonging to a user, a client has to authenticate with a token linking itself to the user.  This token is called an `access token` and contains information on the client, the user and the level of access the client has to the users data. In order to authenticate using such an access token the HTTP header `Authorization` is set to `Bearer <access token>`. The  `access token` is formatted\nas a JSON Web Token according to [RFC7519](https://tools.ietf.org/html/rfc7519)\n\nSuch an `access token` is either returned when\n\n* exchanging an authorization code after a successful OAuth login flow\n* logging in with the user's credentials\n* exchanging a refresh token, which is returned at either of the aforementioned points\n\n**Authentication errors**\n\nIn case of an authentication error a HTTP code 401 response is returned containing further\ndetails on the kind of error in the `WWW-Authenticate` header.\n\nIn addition to the below listed scope the flags are used for simple boolean permissions.\n\n| Flag            | Description                                  |\n| --              | --                                           |\n| submit_payments | Allow submission of payments to bank server  |\n| offline         | Access finX API when the user is not present |\n| create_user     | Allow creation of finX accounts              |\n\n**Example**\n\nThe string `\"accounts=rw submit_payments\"` is URL-encoded and passed as the URL\nparameter `scope`.",
        "scheme": "bearer",
        "bearerFormat": "JWT",
        "x-bearerInfoFunc": "app.decode_token",
        "x-scopes": {
          "accounts=rw": "Modify accounts",
          "accounts=ro": "Read accounts",
          "balance=ro": "Read account balance",
          "securities=ro": "Read securities",
          "transactions=ro": "Read transactions",
          "transactions=rw": "Modify transactions",
          "payments=ro": "Read payments",
          "payments=rw": "Create/modify payments",
          "submit_payments": "Submit payment to service provider",
          "user=ro": "Read user information",
          "user=rw": "Modify user information"
        }
      },
      "client_auth": {
        "x-basicInfoFunc": "app.basic_auth",
        "type": "http",
        "scheme": "basic",
        "description": "Client authentication is performed via [HTTP Basic Auth](https://en.wikipedia.org/wiki/Basic_access_authentication) with client ID as username and client secret as password."
      }
    }
  }
}
```