I'd like to update the user data object in the UI. I know I can do it via the API: https://fusionauth.io/docs/v1/tech/apis/users

dan
@dan
Developer Advocate at FusionAuth.
Best posts made by dan
-
Is there a way to update user data in the UI?
-
Terraform provider for FusionAuth released
There's now an open source terraform provider available: https://github.com/gpsinsight/terraform-provider-fusionauth
It's also on the registry: https://registry.terraform.io/providers/gpsinsight/fusionauth/latest
-
Can I configure the inactivity timeout of the FusionAuth Session cookie?
I have a quick question about FusionAuth and configuring the inactivity timeout of the session cookie it creates. Specifically... Is it possible?
-
RE: Trouble getting the user object post login
OK, we just released 1.18.8 and that is the version you want to use:
In
requirements.txt
:fusionauth-client==1.18.8
And then this is the call you want to make (with
client_id
beforeredirect_uri
) :resp = client.exchange_o_auth_code_for_access_token(request.args.get("code"), client_id, "http://localhost:5000/oauth-callback", client_secret)
-
New website!
We just released an overhaul of the website: https://fusionauth.io/ which includes a new look for the API docs: https://fusionauth.io/docs/v1/tech/
-
Unable to create a registration using the .NET core client
Hiya,
I'm unable to create a user registration using the .NET client libraries: https://fusionauth.io/docs/v1/tech/client-libraries/netcore
I have verified that the API key is basically a super user. I've verified that I'm sending the registration object. I've tried twiddling different properties (verified, insertInstant) and made sure that the application exists. I've added the a user registration to the application manually and it works. Creating a user and setting the userdata works just fine. It just seems like the registration isn't working.
I looked in https://github.com/FusionAuth/fusionauth-netcore-client/issues and https://github.com/FusionAuth/fusionauth-issues/issues but didn't see any relevant issues.
Here's my code so far (you can run it with
fusionauth_api_key=<key> dotnet.exe run -- foo@foo5.com bluepass123 blue
)$ cat usermanager.csproj <Project Sdk="Microsoft.NET.Sdk"> <PropertyGroup> <OutputType>Exe</OutputType> <TargetFramework>netcoreapp3.1</TargetFramework> </PropertyGroup> <ItemGroup> <PackageReference Include="FusionAuth.Client" Version="1.15.7" /> <PackageReference Include="JSON.Net" Version="1.0.18" /> </ItemGroup> </Project>
$ cat Program.cs using System; using io.fusionauth; using io.fusionauth.domain; using io.fusionauth.domain.api; using System.Collections.Generic; using Newtonsoft.Json; namespace usermanager { class Program { private static readonly string apiKey = Environment.GetEnvironmentVariable("fusionauth_api_key"); private static readonly string fusionauthURL = "http://localhost:9011"; private static readonly string tenantId = "66636432-3932-3836-6630-656464383862"; static void Main(string[] args) { if (args.Length != 3) { Console.WriteLine("Please provide email, password and favorite color."); Environment.Exit(1); } string email= args[0]; string password = args[1]; string favoriteColor = args[2]; FusionAuthSyncClient client = new FusionAuthSyncClient(apiKey, fusionauthURL, tenantId); User userToCreate = new User(); userToCreate.email = email; userToCreate.password = password; Dictionary<string, object> data = new Dictionary<string, object>(); data.Add("favoriteColor", favoriteColor); userToCreate.data = data; UserRegistration registration = new UserRegistration(); registration.applicationId = Guid.Parse("4243b56f-0b45-4882-aa23-ac75eea22d22"); registration.verified = true; registration.insertInstant = DateTimeOffset.UtcNow; var registrations = new List<UserRegistration>(); registrations.Add(registration); userToCreate.registrations = registrations; UserRequest userRequest = new UserRequest(); userRequest.sendSetPasswordEmail = false; userRequest.user = userToCreate; string u = JsonConvert.SerializeObject(userRequest); Console.WriteLine(u); var response = client.CreateUser(null, userRequest); string json = JsonConvert.SerializeObject(response); Console.WriteLine(json); if (response.WasSuccessful()) { var user = response.successResponse.user; Console.WriteLine("retrieved user with email: "+user.email); } else if (response.statusCode != 200) { var statusCode = response.statusCode; Console.WriteLine("failed with status "+statusCode); } } } }
Latest posts made by dan
-
RE: I want to embed FusionAuth in a product I sell. Can I do so?
You should read the FusionAuth license, or, rather, have your employers do so.
We've also created a license FAQ which answers common questions about FusionAuth usage. I think this is the relevant section:
I sell downloadable software that contains FusionAuth. What type of license do I need?
And the answer:
You will need a reseller license for FusionAuth in order to resell it to your customers. This license is usually charged per customer rather than per monthly active user. You should contact our sales team to discuss licensing options. They can be reached at sales@fusionauth.io.
-
I want to embed FusionAuth in a product I sell. Can I do so?
I want to embed FusionAuth in a product I have. I won't be selling this product over the internet; I'll be selling this to customers to install in their own networks.
Is this permitted?
-
RE: Not able to Login with Apple ID
What does the error event log say? Have you turned on idp debugging? Does this occur with only one apple id, or with all of them?
Have you ensured that your client secret and client id don't have extra whitespace on either side?
Have you looked at the other apple id posts in the forum?
This one looks like it has some useful info: https://fusionauth.io/community/forum/post/1286
-
RE: How to access FA Dashboard on a remote server?
Hi @richb201 ,
If you are using AWS, you need to make sure you have opened up port 9011 in the security group. Here's some AWS documentation about that.
You probably want a load balancer (nginx or an ALB) in front of your FusionAuth instance to be able to control traffic if needed. This would let you, for example, send different requests based on domain name to different tenants.
(Another option, of course, is purchasing FusionAuth Cloud and letting us run your prod server.
)
-
RE: New user login fails
Did you register the new user with the application?
This doc talks about the two different concepts of authentication and authorization in the context of FusionAuth: https://fusionauth.io/docs/v1/tech/core-concepts/authentication-authorization/
-
RE: The requested identityProviderId is invalid. Unable to complete this login request.
Can you please provide more details?
What you are trying to do? A step by step explanation would be really helpful for anyone trying to understand what problem you ran into.
Thanks,
Dan -
RE: Remove group from user
Looks like this was a regression and based on the github issue a fix should be released in 1.23.4. Sorry about that!
-
RE: How to manually delete a lot of users?
Hiya!
If all the junk users are isolated in a tenant, you can delete the tenant to remove them all.
If they are in the default tenant, or a tenant which you don't want to delete, the easiest way is to use the API:
curl -XDELETE -H"Authorization: apikeyhere" 'https://auth.example.com/api/user/bulk?hardDelete=true&userId=id1&userId=id2&userId=id3'
(not tested, but should work)
You could use the search API +jq to build the list of userIds. If you have a lot, you can also use the request body, see the docs for details.
-
RE: Kickstart in CI environment unpredictable
Hmmm.. Sorry, this sounds frustrating. A couple of things:
- If kickstart is failing/choking because of the size of the file, we want to know about that. Can you please file a bug (preferably with a reproduction steps/kickstart files that cause failure)? https://github.com/fusionauth/fusionauth-issues/issues
- We'd also love to know about the polling failures. Are they replicable? Are you pulling the entire application object?
- It sounds like you'd like a webhook or some other async notification when kickstart is done. Is that right? If that is the case, can you file a feature request: https://github.com/fusionauth/fusionauth-issues/issues There is no way to do that right now, but I think that'd be a dev friendly feature.
Finally to deal with the proximate issue, I would see if you could poll for something lighter weight. Perhaps create a no op lambda at the very end and test to see if that exists?
The other thing is I wonder if FusionAuth is resource starved in CI? What kind of hardware is the CI process running on? Is FusionAuth throwing any errors in the system log while CI is going on? How much memory does it have?
-
RE: No suitable driver found for jdbc:mysql://localhost:3306/login?...
I'm not sure I understand what you are saying. Can you give me a bit more detail?