GALANTHUS / ABI FUNCTION REFERENCE
gln_revolut_oauth_refresh
Declared in <galanthus/c_api/gln_capi.h>.
GLN_API gln_status_t GLN_CALL gln_revolut_oauth_refresh(
gln_backend_t* in_backend,
gln_error_t* out_error);
Purpose
Refreshes persisted Revolut OAuth token state for an opened Revolut backend.
The public C API returns only a status code and optional structured error; refreshed token material remains internal to configured storage.
Return
Returns GLN_OK on success and a non-OK gln_status_t value on failure.
| Type | Nullability | Ownership |
|---|---|---|
gln_status_t | value | value |
Parameters
| Name | Direction | Type | Nullability | Ownership |
|---|---|---|---|---|
in_backend | input | gln_backend_t* | nonnull | borrowed |
out_error | output | gln_error_t* | nullable | caller_allocated_output |
Behavior
The call loads the current persisted token state, performs a Revolut token refresh, and persists the replacement token state on success.
If no refresh-capable token state is available, the call returns GLN_ERR_NOT_FOUND with a refresh-missing issue code.
Persist failures return GLN_ERR_TOKEN_PERSIST_FAILED. Use token-persist error detail helpers to inspect the failing persistence operation.
Redaction
No token strings, key material, or authorization header values are returned through this function.
Use gln_revolut_oauth_status when the host needs redacted token health information.
Example
gln_error_t error = {0};
gln_default_error(&error);
gln_status_t rc = gln_revolut_oauth_refresh(backend, &error);
if (rc != GLN_OK) {
handle_refresh_failure(&error);
}
gln_release_error(&error);