Nico•23d ago
You want to show an image and body text?
You can’t serve a file with body text as far as I know. It would have to be html for that
Niamarou#klm09•23d ago
ok
I want to send an image and its name to my server. How can I do this with hono?
i will save the name on my db and it path to the db
Nico•23d ago
You would need to send it in a multipart form
That way you can send an image plus form data
iiammehmet•23d ago
exactly, I agree with you. You need to define the body request as a multipart or form to attach any file, then get form data from the request
iiammehmet•23d ago
eg: postman
iiammehmet•23d ago
curl --location --request GET 'http://localhost:3000/iamge/' \
--form 'image=@"/C:/Users/5db80f85d8883aa1e13d1d8dfd346401.jpg"'
Nico•23d ago
Thanks for adding more to it, I’m only on my phone
iiammehmet•23d ago
the topic has been resolved. @Niamarou#klm09 i helped. let others know
Niamarou#klm09•23d ago
Thanks
iiammehmet•23d ago
Niamarou#klm09•23d ago
😂
Want results from more Discord servers?
More PostsClient ipHow can I get the client ip, I need it for my rate limiterWhat is the best way to handle the error?What I want is to get the error from server to client using rpc + react query
1. Using `trycatch`
2Running `bun run dev` on a newly created Cloudflare Pages example spits an error```
bun run dev
$ vite
(!) Could not auto-determine entry point from rollupOptions or html files andconnect my hono application endpoints with swagger uihow i can use swagger ui with my hono applicationHow to set "credentials: true" in client side using rpc?I'm using rpc with react query on the client side, this kind of fetching has already credentials: trCookies doesn't processWhen I try to run in my middleware the following
```
setCookie(c, 'test', 'res', { maxAge: 60 * 60 use Context to get vars from wrangler.tomlhow can fix this code. i want to use my openaiApiKey from the wrangler.toml when i create an openai Connect Hono Cloudflare with MongoDBHi. I am using Hono and deploying to Cloudflare. However I am unable to find a way to connect mongodCase insensitive query paramsWe are using hono-zod-openapi to replace an existing API.
Sadly the old API (written in ASP.Net) appPassword hashingHow to hash password?How to setup Hono with Remix/Cloudflare for Vite dev server?From the documentation for Cloudflare Pages, there is an adapter and a plugin, but it is not clear hValidate response objectsUsing the zod validator middleware it is possible to validate params , query, request body like:
``Hono Oauth Provider with JWT issueHey everyone! I'm not sure if this is the right place for me to post about this but recently I wanteDeploy Hono / Bun APII know, I know this is such a newby question but I come from small express apps and other simple ‘clIs there a way to list all request headers ?I have this use case where I am not sure which header key is being sent, I would like to log all heaTyping Middleware JWT and othersCurrently I am trying to type the `c.get('jwtPayload')` that is documented [here](https://hono.dev/mHow to generate openapi.yaml spec with Zod OpenAPI Hono?Is it possible to generate the openapi.yaml spec with Zod OpenAPI Hono from the commandline using a Why use Hono for Next.js backend (route handlers)?I'm creating a full-stack web app and probably using Next.js API/route handler: https://nextjs.org/dContext not finalizedIm trying to build a S3 API and it returns this on every requests
```js
Error: Context is not finalType checking with Hono + prisma + zod -> return json date (expect string)HI, i m usin openAPi I declared return params in my route
```
const getUserRoute = createRoute({