3eif
3eif
Explore posts from servers
TTCTheo's Typesafe Cult
Created by 3eif on 1/11/2024 in #questions
How to protect pages using Next Auth
i dont think its that bad
16 replies
TTCTheo's Typesafe Cult
Created by 3eif on 1/11/2024 in #questions
How to protect pages using Next Auth
I think ima just use jwt tokens
16 replies
TTCTheo's Typesafe Cult
Created by 3eif on 1/11/2024 in #questions
How to protect pages using Next Auth
I might just use JWT for simplicity at this point
16 replies
TTCTheo's Typesafe Cult
Created by 3eif on 1/11/2024 in #questions
How to protect pages using Next Auth
I think it's a bit too complicated for me though
16 replies
TTCTheo's Typesafe Cult
Created by 3eif on 1/11/2024 in #questions
How to protect pages using Next Auth
Thank you for sending this
16 replies
TTCTheo's Typesafe Cult
Created by 3eif on 1/11/2024 in #questions
How to protect pages using Next Auth
Cuz I can't call the db to get the secret in middleware
16 replies
TTCTheo's Typesafe Cult
Created by 3eif on 1/11/2024 in #questions
How to protect pages using Next Auth
I have to use JWT tokens if I'm using middleware
16 replies
TTCTheo's Typesafe Cult
Created by 3eif on 1/11/2024 in #questions
How to protect pages using Next Auth
Yes I'm using next auth
16 replies
TTCTheo's Typesafe Cult
Created by 3eif on 12/29/2023 in #questions
Error when using uploadthig uploadFilesFromUrl
Code:
"use server";

import OpenAI from "openai";
import { UTApi } from "uploadthing/server";

const utapi = new UTApi();

const openai = new OpenAI({
apiKey: process.env.OPENAI_API_KEY ?? "",
});

export async function generateLegoSet(formData: FormData) {
....
const dalleImageUrl = image.data[0].url; // i get this from somewhere
const imageUrl = await utapi.uploadFilesFromUrl([dalleImageUrl!]);
}
"use server";

import OpenAI from "openai";
import { UTApi } from "uploadthing/server";

const utapi = new UTApi();

const openai = new OpenAI({
apiKey: process.env.OPENAI_API_KEY ?? "",
});

export async function generateLegoSet(formData: FormData) {
....
const dalleImageUrl = image.data[0].url; // i get this from somewhere
const imageUrl = await utapi.uploadFilesFromUrl([dalleImageUrl!]);
}
3 replies
TTCTheo's Typesafe Cult
Created by 3eif on 12/20/2023 in #questions
What are the files in the /trpc folder used for in T3 App Router?
This answered my question
14 replies
TTCTheo's Typesafe Cult
Created by 3eif on 12/20/2023 in #questions
What are the files in the /trpc folder used for in T3 App Router?
Thank you both
14 replies
TTCTheo's Typesafe Cult
Created by 3eif on 10/3/2023 in #questions
Upload file to UploadThing via url
NEVERMIND I FOUND UPLOADFILEFROMURL 😀
4 replies