Skip to content

UserAuthorizer adds approval_prompt=force and conflicts with prompt=consent #1443

@arttom

Description

@arttom

Environment details

  1. OS type and version: Any
  2. Java version: 21/any
  3. version(s): 1.23 (but code exists in the newest as well)

Steps to reproduce

  1. Using Google Ads library (v.31.0.0)
  2. Create Authorization request by URL
  3. It contains approval_prompt=force by default

Code example

UserAuthorizer userAuthorizer = UserAuthorizer.newBuilder()
                .setClientId(ClientId.of("123", null))
                .setScopes(Arrays.asList(googleProperties.ads().scopes().split(" ")))
                .setCallbackUri("/customer/google)
                .build();

        return userAuthorizer
                .getAuthorizationUrl(
                        userId,
                        state,
                        URI.create(serverHost),
                        Map.of("prompt", "consent"));

External references such as API reference guides

https://developers.google.com/identity/openid-connect/openid-connect#prompt

The approval_prompt is not even mentioned in the documentation

Any additional information below

After using it like this we get an error Conflict params: approval_prompt and prompt
but there is no way to remove approval_prompt parameter, except manual operation after URL is created.

Metadata

Metadata

Assignees

No one assigned

    Labels

    priority: p3Desirable enhancement or fix. May not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions