Welcome to the Kinde community

Updated 2 months ago

Creating an organization with the ruby sdk

At a glance

A community member is experiencing issues with the Ruby SDK for creating an organization. The documentation suggests using the syntax client.organizations.create_organization(create_organization_request: {name: "new_org"}), but the member is getting errors saying the name is missing and required. Dropping the create_organization_request key makes it work, which seems unexpected. Additionally, the response is not an organization instance, and the member has to call response.organization to retrieve it, which differs from the user API.

The community members are investigating the issue, with one member speaking to a Ruby SDK expert and another getting another Ruby expert to look into it. They are asking the original poster for the version of the Ruby SDK they are using, and the poster responds that they are using a forked version of the latest version (1.2.3) because it would not run with Ruby 3 without the changes made.

The community members are continuing to work on the issue and will provide updates to the original poster as they progress.

Useful resources

Hey guys. The Ruby SDK documentation for creating an organization suggests the following syntax: client.organizations.create_organization(create_organization_request: {name: "new_org"}), (source: https://docs.kinde.com/developer-tools/sdks/backend/ruby-sdk/#create-an-organization) however, I was getting errors suggesting the name was missing (and is required). For some reason, if I dropped the create_organization_request key, it works. Is this the expected behaviour? Also, the response was not an organization instance. I had to call response.organization to retrieve it. This differs slightly from the user API.

P
J
O
7 comments

Hey ,
Thanks for reaching out.

Sorry you are experiencing these issues in the SDK and documentation.
I will speak to my teammate who is an expert on the Ruby SDK and get back to you.

Hey ,
We are still investigating this issue.
I will continue to update you as we progress with fixing this issue.

any update on this issue?

Hey ,
We are getting another Ruby expert to look into this issue.

Sorry that it's taking longer than expected.
I will continue to keep you in the loop.

Hey ,
In the meantime, are you able to let me know the version of the Ruby SDK you are experiencing these issues with?

module KindeSdk
  VERSION = "1.2.3"
end
I'm using a forked version of the latest version https://github.com/kinde-oss/kinde-ruby-sdk/pull/32 because it would not run with Ruby 3 without the changes made

Thanks for the quick reply and all this information.
My teammate is already looking into this issue.

I will continue to update you as we progress in fixing this issue.

Add a reply
Sign up and join the conversation on Slack