mirror of
https://github.com/NginxProxyManager/nginx-proxy-manager.git
synced 2025-11-13 13:55:14 +00:00
- Add help docs for most sections - Add translations documentation - Fix up todos - Remove german translation
25 lines
435 B
TypeScript
25 lines
435 B
TypeScript
import * as api from "./base";
|
|
import type { User } from "./models";
|
|
|
|
export interface AuthOptions {
|
|
type: string;
|
|
secret: string;
|
|
}
|
|
|
|
export interface NewUser {
|
|
name: string;
|
|
nickname: string;
|
|
email: string;
|
|
isDisabled?: boolean;
|
|
auth?: AuthOptions;
|
|
roles?: string[];
|
|
}
|
|
|
|
export async function createUser(item: NewUser, noAuth?: boolean): Promise<User> {
|
|
return await api.post({
|
|
url: "/users",
|
|
data: item,
|
|
noAuth,
|
|
});
|
|
}
|