httr (version 1.2.1)

jwt_signature: Generate a JWT signature given credentials.

Description

As described in https://developers.google.com/accounts/docs/OAuth2ServiceAccount

Usage

jwt_signature(credentials, scope, aud, duration = 60L * 60L)

Arguments

credentials

Parsed contents of the credentials file.

scope

A space-delimited list of the permissions that the application requests.

duration

Duration of token, in seconds.

Examples

Run this code
# NOT RUN {
cred <- jsonlite::fromJSON("~/Desktop/httrtest-45693cbfac92.json")
jwt_signature(cred, "https://www.googleapis.com/auth/userinfo.profile")
# }

Run the code above in your browser using DataCamp Workspace