Conversation
pyproject.toml
Outdated
| aiohttp = {extras = ["speedups"], version = "^3.7.3"} | ||
| pydantic = "^1.7.3" | ||
| python = "^3.11" | ||
| aiohttp = "3.9.0" |
There was a problem hiding this comment.
is there a reason this needs to be pinned to exactly 3.9.0?
There was a problem hiding this comment.
I had to use a specific beta version during a few weeks (3.9.0b0), because of the 3.11 python version I was using.
When it was finally included in the 3.9.0, I forgot to put it back.
I'll move it back to : aiohttp = {extras = ["speedups"], version = "^3.9.0"}
clerk/organizations.py
Outdated
|
|
||
| async def list(self) -> List[types.Organization]: | ||
| """Retrieve a list of all organizations""" | ||
| async with self._client.get(self.endpoint) as r: |
There was a problem hiding this comment.
| async with self._client.get(self.endpoint) as r: | |
| async with self._client.get(self.endpoint) as resp: |
let's use resp instead of r for all of these methods
There was a problem hiding this comment.
Please update the rest of the methods and make sure the code still works. There's still a reference to s rather than resp_json
There was a problem hiding this comment.
Sorry about that, should have tested it.
Not a big user of one-letter vars myself, I kept them originally to be "coherent" with your methods in clients.py
I fixed this issues in my last commit.
Co-authored-by: Elijah Wilson <5739698+tizz98@users.noreply.github.com>
812c864 to
b2a16a0
Compare
[IMP] This PR implements 4 endpoints related to the Clerk organizations :
list: https://clerk.com/docs/reference/backend-api/tag/Organizations#operation/ListOrganizationsget: https://clerk.com/docs/reference/backend-api/tag/Organizations#operation/GetOrganizationdelete: https://clerk.com/docs/reference/backend-api/tag/Organizations#operation/DeleteOrganizationupdate: https://clerk.com/docs/reference/backend-api/tag/Organizations#operation/UpdateOrganization[FIX] Also add
"Content-type" : "application/json"in the HTTP request header, because it is now required for every clerk API call.