# OpenAi Api Pdf reader for Java

**URL:** <https://community.openai.com/t/openai-api-pdf-reader-for-java/957462>\
**Category:** API\
**Tags:** api, assistants-api, java, simple-openai\
**Created:** [September 26, 2024, 1:05pm UTC](https://community.openai.com/t/openai-api-pdf-reader-for-java/957462 "2024-09-26T13:05:57Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![platypus](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/platypus/32/759972_2.png) [@platypus](https://community.openai.com/u/platypus)\
**Post date:** [September 26, 2024, 3:51pm UTC](https://community.openai.com/t/openai-api-pdf-reader-for-java/957462/2 "2024-09-26T15:51:58Z")

</div>

Hi @Skylark839 and welcome to the community!

I did a quick search and found [this Java package](https://github.com/TheoKanning/openai-java), but looks like it’s been archived.

However, all OpenAI API examples, including Assistants API work with standard `curl` (HTTP) requests. So any Java library that is able to behave like `curl` equivalent (sending HTTP requests to some URI), should work fine.

For example, on [this page](https://platform.openai.com/docs/assistants/deep-dive/creating-assistants), you can see how to do everything by selecting “curl” option. To upload a file for example, you would do this:

```auto
curl https://api.openai.com/v1/files \
  -H "Authorization: Bearer $OPENAI_API_KEY" \
  -F purpose="assistants" \
  -F file="@revenue-forecast.csv"

```

I am not up to speed with all the Java web features but any Java lib/module that can execute that should be good to go.

---

_[View the full topic](https://community.openai.com/t/openai-api-pdf-reader-for-java/957462)._
