All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.twilio.jwt.client.IncomingClientScope Maven / Gradle / Ivy

There is a newer version: 10.6.4
Show newest version
package com.twilio.jwt.client;

import com.google.common.base.Joiner;

import java.io.UnsupportedEncodingException;

/**
 * Scope token for Incoming Clients.
 */
public class IncomingClientScope implements Scope {

    private static final String SCOPE = Joiner.on(':').join("scope", "client", "incoming");

    private final String clientName;

    public IncomingClientScope(String clientName) {
        this.clientName = clientName;
    }

    @Override
    public String getPayload() throws UnsupportedEncodingException {
        String query = Joiner.on('=').join("clientName", this.clientName);
        return Joiner.on('?').join(SCOPE, query);
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy