Skip to content

How to authenticate using oauth in code? #405

@m00nwtchr

Description

@m00nwtchr

Hello I have 2fa auth enabled on my acc and because of that I need to auth using oauth (and I'd also like for the creds to be hard coded but I wont do that with my pass). This is what I have tried to do that:

           GitHub github = new GitHubBuilder().withOAuthToken("TOKEN", "EMAIL").build();

but it just thrown an error.
Please help

EDIT:
another question:
is it possible to auth using client secret and id? (https://developer.github.com/v3/#increasing-the-unauthenticated-rate-limit-for-oauth-applications)

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