Skip to content

Look into adding more namespaces (or revising namespace logic) #5

@maxachis

Description

@maxachis

The namespace logic currently has two namespaces:

class Namespaces(Enum):
    AUTH = "auth"
    LOCATIONS = "locations"

If we want to update this to be used by the other projects, we'll need more namespaces.

At the same time, maybe this, along with the below, isn't the best way to build URLs accessing the PDAP API 🤔:

    def build_url(self, namespace: Namespaces, subdomains: Optional[list[str]] = None) -> str:
        """
        Build url from namespace and subdomains
        :param namespace:
        :param subdomains:
        :return:
        """
        url = f"{self.api_url}/{namespace.value}"
        if subdomains is not None:
            url = f"{url}/{'/'.join(subdomains)}"
        return url

So we should investigate what makes the most sense for this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions