Skip to content

Conversation

jamesmyatt
Copy link

/requesttoken has sightly different response using username-password pair. See https://docs.tigergraph.com/tigergraph-server/3.10/api/built-in-endpoints#_request_a_token

@jamesmyatt
Copy link
Author

BTW, there's a lot of logic in getToken that could be refactored.

For example, if setToken is False, then you can bypass _token and just set apiToken to None directly. See

Also you can use _set_auth_header rather than duplicate the code in _parse_token_response.

@jamesmyatt
Copy link
Author

Actually, _set_auth_header doesn't work when apiToken is a tuple!

@jamesmyatt jamesmyatt changed the title Fix getToken for TG 3.x and username-password pair Bug fix: getToken for TG 3.x and username-password pair Aug 12, 2025
@jamesmyatt
Copy link
Author

@qe-tigergraph , can we get this bug fix merged?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant