Zum Hauptinhalt springen

CreateDemoAccount

POST 

/demo/accounts

Create an account at the demo broker for the logged-in user. The account will have a default set of two empty portfolios by default. If the setting isSinglePortfolio is set, only one portfolio is created.

The account as well as the two portfolios have a randomly generated name.

To log into an account, use the account's generated name as username (Account name) in AddSession.

  • with the password 42, the login will succeed immediately
  • with the password 1337, a challenge with type text will be returned which must be completed by using addSessionCompleteChallenge (with a challengeResponse 42)
  • with the password 7, a challenge with type base64png will be returned which must be completed by using addSessionCompleteChallenge (with a challengeResponse 42)
  • other passwords will not allow to log in

The demo broker simulates different market scenarios for various ISINs (e.g., partial executions, error cases, or specific cost structures). A complete overview of these test ISINs and their behavior can be found in the guide Demo Broker Test Scenarios.

Behavior of PortfolioQuotes in the demo broker:

  • portfolio 1 starts with 100.000€ cash. portfolio 2 has two cash accounts, one starts with 100.000€, one with 100.000$.
  • when cash account values are summed up, we just assume an exchange rate of 1:1
  • each open buy order reserves 10€ cash from the availableCash
  • profit loss of the portfolio is the sum of the position's profit loss
  • if a EUR cashAccount has the value 0,00€, its hideInOverviews property is set to true. This can be used to test the frontend's behavior when a cash account is hidden.

Request

Responses

Ok