Run the services
- minio
- gotrue (supabase)
- galatea-server
- postgres
docker compose up -d --build
// Build the client
const transport = createConnectTransport({
baseUrl: "http://localhost:8080",
useHttpGet: true,
});
const client = createPromiseClient(AuthService, transport);
// Call signUp on the API
client.signUp({
email: "[email protected]",
password: "devdev",
});
// Call verify on the API
// Get the token from the SMTP blackhole (mailhog, http://localhost:8025)
client.verify({
type: "signup",
email: "[email protected]",
token: "796956",
});
// Call signIn on the API
const resp = await client.signIn({
email: "[email protected]",
password: "devdev",
});
// Call check on the API
client.check({}, { headers: { Authorization: `Bearer ${resp.accessToken}` } });
If successful, your token is valid! Use it for all authenticated requests.