clerk / clerk-sdk-ruby

Access the Clerk Backend API from Ruby
MIT License
24 stars 10 forks source link

feat: Add clerk_organization & clerk_organization_id helpers #22

Closed agis closed 1 year ago

agis commented 1 year ago

This fetches the organization ID of the currently authenticated session, if any. Otherwise it returns nil.

agis commented 1 year ago

What about clerk_organization?

Thought about that, but it would be inconsistent with the other helpers. We currently have:

Following that same convention, it made sense for it to be suffixed with _id since it returns an ID.

Then, I chose org over organization for convenience/brevity. Do you think we should change it to clerk_organization_id?

SokratisVidros commented 1 year ago

That's right. I am suggesting to have both, clerk_organization should return the full clerk_organization object.

agis commented 1 year ago

Overhauled this to introduce two new helpers:

@SokratisVidros PTAL.