appwrite/docs/examples/1.0.x/server-ruby/examples/users/create-argon2user.md

14 lines
409 B
Markdown
Raw Normal View History

2022-09-14 12:11:36 +00:00
require 'Appwrite'
2022-09-01 04:49:47 +00:00
2022-09-14 12:11:36 +00:00
include Appwrite
2022-09-01 04:49:47 +00:00
2022-09-14 12:11:36 +00:00
client = Client.new
2022-09-01 04:49:47 +00:00
.set_endpoint('https://[HOSTNAME_OR_IP]/v1') # Your API Endpoint
.set_project('5df5acd0d48c2') # Your project ID
.set_key('919c2d18fb5d4...a2ae413da83346ad2') # Your secret API key
2022-09-14 12:11:36 +00:00
users = Users.new(client)
2022-09-01 04:49:47 +00:00
response = users.create_argon2_user(user_id: '[USER_ID]', email: 'email@example.com', password: 'password')
puts response.inspect