Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Not able to update developer with long name

I am using the endpoint described here to try to update a user with a long user name. When I do, even if I use a one character long name, I get a 400 error and the message "Invalid Developer User name <>" and the <> contains the old user name, not the new one I'm trying to change it to. Seems like this user is now stuck.

On a related note, what are the length restrictions on username/first name/last name?

Thanks!

3 2 215
2 REPLIES 2

Reproduction

I've went ahead and created a sample developer, with a quite long email

{
  "email": "sampleeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee@google.com",
  "firstName": "Cristian",
  "lastName": "Bulzan",
  "userName": "username",
  "developerId": "972af2f4-xxxxxxxxxxx",
  "organizationName": "xxxx",
  "status": "active",
  "createdAt": "1721376352230",
  "lastModifiedAt": "1721376352230"
}

Let me know if your's has even more characters.

Also, you could use this Management API in order to list all the developers, you should be able to see the one you refer to as <> in there, perhaps you have a typo.

Now, if I use the Management API you mentioned, with the email above I get a successful 200 OK response; here is the sanitized curl call I used:

curl --request PUT \
  'https://apigee.googleapis.com/v1/organizations/ORG_NAME/developers/sampleeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee%40google.com?key=[YOUR_API_KEY]' \
  --header 'Authorization: Bearer [YOUR_ACCESS_TOKEN]' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data '{"email":"updated@google.com","firstName":"Cristian2","lastName":"Bulzan2","userName":"updated."}' \
  --compressed

And the JSON returned should looks like:

{
  "email": "updated@google.com",
  "firstName": "Cristian2",
  "lastName": "Bulzan2",
  "userName": "updated.",
  "developerId": "972af2f4-xxxxxxx",
  "organizationName": "xxxx",
  "status": "active",
  "createdAt": "1721376352230",
  "lastModifiedAt": "1721376796661"
}

You can either use my curl call or do it through the Management Api UI:

razvanbulzan_0-1721377047721.png

Regarding limits for developers, the naming guidelines do not mention anything special, although you may take that into consideration as the issue might not be the length but some special character that might need to be encoded and therefore not able to be processed on the Management API, for example @ sign on the curl call is represented like %40.

Hope this helps.




Hello @JacobHume! If the response you got solves your question, please mark it as solved. Thanks for contributing to the community!