Skip to content

data module is not able to build correct URLs if there is a {braincube-name} placeholder in the configuration #32

@MaximeMorille

Description

@MaximeMorille

Currently, all endpoints called by the data module are not working if the braincube_base_url configuration contains the {braincube-name} placeholder.

I would expect the following script to work:

from braincube_connector import client, braincube

configuration = {
  "api_key": "<your-api-key>",
  "braincube_base_url": "https://api.mybraincube.com/braincube/{braincube-name}",
  "sso_base_url": "https://mybraincube.com",
}
client.get_instance(config_dict=configuration)

demo = braincube.get_braincube("demo")

print(demo)

mb20 = demo.get_memory_base("20")
print(mb20.get_name())

print(mb20.get_order_variable_long_id()) # json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0) exception

version: 2.5.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions