alepha@docs:~/docs/reference/primitives$
cat $remote.md1 min read
#$remote
#Import
typescript
1import { $remote } from "alepha/server/links";
#Overview
$remote is a primitive that allows you to define remote service access.
Use it only when you have 2 or more services that need to communicate with each other.
All remote services can be exposed as actions, ... or not.
You can add a service account if you want to use a security layer.
#Options
| Option | Type | Required | Description |
|---|---|---|---|
url |
string | (() => string) |
Yes | The URL of the remote service |
name |
string |
No | The name of the remote service. |
noInternal |
boolean |
Yes | If true, the remote service won't be available internally, only through the proxy. |
serviceAccount |
ServiceAccountPrimitive |
No | For communication between the server and the remote service with a security layer |