Skip to content

401 error #36

@DevJoey

Description

@DevJoey

I get this exception
org.jsoup.HttpStatusException: HTTP error fetching URL. Status=401, URL=https://www.patreon.com/api/oauth2/token
at org.jsoup.helper.HttpConnection$Response.execute(HttpConnection.java:682)
at org.jsoup.helper.HttpConnection$Response.execute(HttpConnection.java:629)
at org.jsoup.helper.HttpConnection.execute(HttpConnection.java:261)
at org.jsoup.helper.HttpConnection.post(HttpConnection.java:256)
at com.patreon.PatreonOAuth.getTokens(PatreonOAuth.java:57)
at net.proxysocke.gittest.LoadUp.main(LoadUp.java:34)

my code
public static String clientid = "sec";
public static String clientsecret = "sec";
public static String redirectUri = "my url";

public static String code = "code";

public static void main(String[] args) {
	
	try {
		PatreonOAuth authClient = new PatreonOAuth(clientid, clientsecret, redirectUri);
		PatreonOAuth.TokensResponse tok = authClient.getTokens(code);
		
		
	} catch (Exception e) {
		e.printStackTrace();
	}

}
}

What i make wrong and what is code how i can get a "code" please provide a better documentation. the api is useless

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions