create: (
spec: any,
) =>
| {
errors: string[];
ok: boolean;
readiness?: undefined;
relationship?: undefined;
}
| {
errors?: undefined;
ok: boolean;
readiness: { missing: string[]; ready: boolean };
relationship: {};
} = create
Type Declaration
-
- (
spec: any,
):
| {
errors: string[];
ok: boolean;
readiness?: undefined;
relationship?: undefined;
}
| {
errors?: undefined;
ok: boolean;
readiness: { missing: string[]; ready: boolean };
relationship: {};
}
-
Returns
| {
errors: string[];
ok: boolean;
readiness?: undefined;
relationship?: undefined;
}
| {
errors?: undefined;
ok: boolean;
readiness: { missing: string[]; ready: boolean };
relationship: {};
}
{ ok: true, relationship, readiness }, or { ok: false, errors }
Creates a relationship, always disabled; refuses a bad or duplicate id, an unknown role or protocol, and a full container.