Return to Project-GC

Welcome to Project-GC Q&A. Ask questions and get answers from other Project-GC users.

If you get a good answer, click the checkbox on the left to select it as the best answer.

Upvote answers or questions that have helped you.

If you don't get clear answers, edit your question to make it clearer.

0 votes
658 views
I am not familiar with how the Geocacing Live API works. I am aware that they use OAuth to authenticate access to their data, and that it is through these auth tokens that project-gc is able to for instance log trackables discovered in my name. It is not clear, however, how an account is identified.

When a person changes a profile name on geocaching.com, he or she does so within their own system. It it thus a trivial matter to link old usernames to new (if they so choose). Depending on how the API is, a user name change may be nontrivial to implement for API users such as project-gc.

Since project-gc operate with user-specific settings (and indeed paid membership) that is tied in with the geocaching.com user system, does these settings (and any paid membership) go on to the new account on name change on geocaching.com ?

My question asked in another way: Does the API provide (and does project-gc use) an unchanging UID for API users that will always refer to a specific geocaching.com user (regardless of username), or does it only use username (which can change) ?
related to an answer for: changing geoname
closed with the note: Target. has provided a satisfactory answer to the question.
in Support and help by Funky_Boris (9.8k points)
closed by Funky_Boris

1 Answer

+2 votes
 
Best answer
I am quite sure that all API Calles uses User ID not User name
You can read the API spec here
The second link it to download a user profile and the option is user id
https://staging.api.groundspeak.com/Live/v6beta/geocaching.svc/help
https://staging.api.groundspeak.com/Live/v6beta/geocaching.svc/help/operations/GetAnotherUsersProfile
I could not even found a get id from username call but i might have missed it

And if you look at you cookies for pgc the one named pgc_uid has the value of you gc.com user ID

All gc.com information for computer used include the ID look at the GPX files they have ID and name for all logs

From a programming standpoint i would be surprised it the databases was key by username. Then you would need to have long text data fields in many tables instead of a single 32 bit int
by Target. (Expert) (104k points)
selected by Funky_Boris
Thank you very much for those API documentation links - I have been looking for them for quite a while now :)

The XML schemas included in the documentation seem to corroborate your claims. UserID is declared of type long, which would be a rather cumbersome representation of a username, but perfect for a strictly numerical ID :)

I consider the question answered and will now close it. If other admins have anything to add, they can reopen it :)
...