Skip to content

rc_client_begin_fetch_hash_library

Jamiras edited this page Dec 21, 2025 · 1 revision

Fetches a list of hashes for a console and the associated game identifier.

Syntax

rc_client_async_handle_t* rc_client_begin_fetch_hash_library(
    rc_client_t* client,
    uint32_t console_id,
    rc_client_fetch_hash_library_callback_t callback,
    void* callback_userdata
);

Parameters

client

The rc_client_t to use to fetch the leaderboard entries.

console_id

The unique identifier of the console to query.

callback

Function to call when the list is available.

callback_userdata

Additional information to pass to the callback function.

Returns

Pointer to an rc_client_async_handle_t that can be passed to rc_client_abort_async to cancel the user progress query request. The rc_client_async_handle_t is invalid after callback has been called.


rc_client_fetch_all_user_progress_callback_t

void (*rc_client_fetch_hash_library_callback_t)(
    int result,
    const char* error_message,
    rc_client_hash_library_t* list,
    rc_client_t* client,
    void* userdata
);

result

RC_OK on success, or an error code indicating the failure.

result problem
RC_OK Hash mapping entries were successfully retrieved.
RC_INVALID_STATE Generic failure. See error_message for details.
RC_INVALID_JSON Server response could not be processed.
RC_MISSING_VALUE Server response was not complete.
RC_API_FAILURE Error occurred on the server. See error_message for details.
RC_OUT_OF_MEMORY Memory could not be allocated to hold the response.

error_message

NULL on success, or a message related to a non-successful result.

list

Pointer to a rc_client_hash_library_t object containing the requested hash mappings.

It must be released by calling rc_client_destroy_hash_library.

Will be NULL if an error occurred.

client

The rc_client_t that was handling the load game attempt.

userdata

A client provided pointer passed to the begin function as callback_userdata.


rc_client_hash_library_t

typedef struct rc_client_hash_library_t {
  rc_client_hash_library_entry_t* entries;
  uint32_t num_entries;
} rc_client_hash_library_t;

entries

An array of hash mapping entries.

num_entries

The number of entries in the entries array.


rc_client_hash_library_entry_t

typedef struct rc_client_hash_library_entry_t{
  char hash[33];
  uint32_t game_id;
} rc_client_hash_library_entry_t;

hash

The generated hash for a specific version of a game (or a single disc of a multidisc game).

game_id

The unique identifier of the game.

Remarks

The rc_client_hash_library_t instance created by this function must be released by calling rc_client_destroy_hash_library.

Minimum version: 12.0.0

See also

rc_client_begin_fetch_game_titles

rc_client_destroy_hash_library

rcheevos
rc_client

Integration guide

client

user

game

processing

additional data

rc_client_raintegration

Integration guide

rc_runtime
rhash
rapi

common

user

runtime

info

Clone this wiki locally