# Built-in classes/methods instead of authorize and token endpoints

**URL:** <https://devforum.okta.com/t/built-in-classes-methods-instead-of-authorize-and-token-endpoints/18183>\
**Category:** Questions\
**Tags:** java\
**Created:** [November 22, 2021, 4:42pm UTC](https://devforum.okta.com/t/built-in-classes-methods-instead-of-authorize-and-token-endpoints/18183 "2021-11-22T16:42:31Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![angeline.alex](https://avatars.discourse-cdn.com/v4/letter/a/ecd19e/32.png) [@angeline.alex](https://devforum.okta.com/u/angeline.alex)\
**Post date:** [November 22, 2021, 4:42pm UTC](https://devforum.okta.com/t/built-in-classes-methods-instead-of-authorize-and-token-endpoints/18183/1 "2021-11-22T16:42:31Z")

</div>

I am using authorize to redirect my page to okta login page. Using token endpoints once i get the access and id token once i get code from authrorize endpoint response. Then validating the access token and getting user details.

I would like know if there are any built-in library that i can use instead of my own composed URL for authorization and instead of token endpoint i can just something from the existing library?

I am using java application.

---

<div class="post-metadata">

**Author:** ![andrea](https://sea1.discourse-cdn.com/oktadev/user_avatar/devforum.okta.com/andrea/32/2172_2.png) [@andrea](https://devforum.okta.com/u/andrea)\
**Post date:** [November 22, 2021, 5:11pm UTC](https://devforum.okta.com/t/built-in-classes-methods-instead-of-authorize-and-token-endpoints/18183/2 "2021-11-22T17:11:12Z")

</div>

For Java, we have a Spring Boot Starter you can use that will handle the flow for you: [GitHub - okta/okta-spring-boot: Okta Spring Boot Starter](https://github.com/okta/okta-spring-boot). You can find complete sample applications here: [GitHub - okta/samples-java-spring: Spring Boot samples](https://github.com/okta/samples-java-spring)

---

<div class="post-metadata">

**Author:** ![angeline.alex](https://avatars.discourse-cdn.com/v4/letter/a/ecd19e/32.png) [@angeline.alex](https://devforum.okta.com/u/angeline.alex)\
**Post date:** [November 22, 2021, 5:17pm UTC](https://devforum.okta.com/t/built-in-classes-methods-instead-of-authorize-and-token-endpoints/18183/3 "2021-11-22T17:17:10Z")

</div>

We are not using sprint boot in our application. Just java. Any option for that?

---

<div class="post-metadata">

**Author:** ![andrea](https://sea1.discourse-cdn.com/oktadev/user_avatar/devforum.okta.com/andrea/32/2172_2.png) [@andrea](https://devforum.okta.com/u/andrea)\
**Post date:** [February 8, 2024, 7:59pm UTC](https://devforum.okta.com/t/built-in-classes-methods-instead-of-authorize-and-token-endpoints/18183/4 "2024-02-08T19:59:29Z")

</div>

Closed on February 8, 2024, 7:59pm UTC


