most-dawn-89885
05/08/2023, 4:56 PMory-client python sdk but having some issues.
i installed ory-client but in using the sdk, for even the test tutorial(https://github.com/ory/sdk/blob/master/clients/client/python/docs/MetadataApi.md#get_version), i get the error:
NotFoundException: Status Code: 404 Reason: Not Found HTTP response headers: HTTPHeaderDict({'Date': 'Mon, 08 May 2023 00:44:14 GMT', 'Content-Type': 'application/json', 'Content-Length': '144', 'Connection': 'keep-alive', 'vary': 'Origin', 'ory-network-request-id': '76b94ada-2bf2-90ea-a381-74edd712181c', 'CF-Cache-Status': 'DYNAMIC', 'Set-Cookie': '__cflb=0H28vgXdDEYCN6ddXsaRCbLqjUk6h4A7eP8HnHf9dF1; SameSite=None; Secure; path=/; expires=Mon, 08-May-23 01:44:14 GMT; HttpOnly', 'Server': 'cloudflare', 'CF-RAY': '7c3dac50cb9d23bf-LHR', 'alt-svc': 'h3=":443"; ma=86400, h3-29=":443"; ma=86400'}) HTTP response body: {"error":{"code":404,"status":"Not Found","request":"76b94ada-2bf2-90ea-a381-74edd712181c","message":"Requested url does not match any rules"}}
Is there any idea on how i can fix this or if i'm missing to set up something that wasn't included in the docs?bland-eye-99092
05/08/2023, 7:52 PMmost-dawn-89885
05/08/2023, 8:12 PMconfiguration = ory_client.Configuration(
host = "<https://playground.projects.oryapis.com>"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure Bearer authorization: oryAccessToken
configuration = ory_client.Configuration(
access_token = 'YOUR_BEARER_TOKEN'
)
then tried something specific for my project:
configuration = ory_client.Configuration(
host = "<https://elegant-liskov-q3be2292gk.projects.oryapis.com/>"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure Bearer authorization: oryAccessToken
configuration = ory_client.Configuration(
access_token = 'ory_pat_AslFFXTtz05uRwbia5fwKiAiP6wZuNpp'
)
both the same resultbland-eye-99092
05/08/2023, 8:17 PMmost-dawn-89885
05/08/2023, 8:38 PMException when calling IdentityApi->list_identities: Status Code: 403
Reason: Forbidden
HTTP response headers: HTTPHeaderDict({'Date': 'Mon, 08 May 2023 19:49:30 GMT', 'Content-Type': 'application/json', 'Content-Length': '167', 'Connection': 'keep-alive', 'vary': 'Origin', 'ory-network-request-id': 'ebf2bb33-c0e9-9b3a-ba64-4736453a41be', 'CF-Cache-Status': 'DYNAMIC', 'Set-Cookie': '__cflb=0H28vgXdDEYCN6ddXsaRCbLqjUk6h4A7b43pWRyFLqZ; SameSite=None; Secure; path=/; expires=Mon, 08-May-23 20:49:30 GMT; HttpOnly', 'Server': 'cloudflare', 'CF-RAY': '7c4439f39ceb23b9-LHR', 'alt-svc': 'h3=":443"; ma=86400, h3-29=":443"; ma=86400'})
HTTP response body: {"error":{"code":403,"status":"Forbidden","request":"ebf2bb33-c0e9-9b3a-ba64-4736453a41be","message":"Access credentials are not sufficient to access this resource"}}
although, i am unsure, looking at the error message, on what access credentials are needed to access my resource. as a context, i used my host and access token(which is the api key). what more do i require to work with Ory apis?