1 | import { HookContext, NullableId, Params } from '@feathersjs/feathers';
|
2 | export declare const METHOD_HEADER = "x-service-method";
|
3 | export interface ServiceParams {
|
4 | id: NullableId;
|
5 | data: any;
|
6 | params: Params;
|
7 | }
|
8 | export declare const statusCodes: {
|
9 | created: number;
|
10 | noContent: number;
|
11 | methodNotAllowed: number;
|
12 | success: number;
|
13 | seeOther: number;
|
14 | };
|
15 | export declare const knownMethods: {
|
16 | [key: string]: string;
|
17 | };
|
18 | export declare function getServiceMethod(_httpMethod: string, id: unknown, headerOverride?: string): string;
|
19 | export declare const argumentsFor: {
|
20 | get: ({ id, params }: ServiceParams) => (Params<import("@feathersjs/feathers").Query> | NullableId)[];
|
21 | find: ({ params }: ServiceParams) => Params<import("@feathersjs/feathers").Query>[];
|
22 | create: ({ data, params }: ServiceParams) => any[];
|
23 | update: ({ id, data, params }: ServiceParams) => any[];
|
24 | patch: ({ id, data, params }: ServiceParams) => any[];
|
25 | remove: ({ id, params }: ServiceParams) => (Params<import("@feathersjs/feathers").Query> | NullableId)[];
|
26 | default: ({ data, params }: ServiceParams) => any[];
|
27 | };
|
28 | export declare function getStatusCode(context: HookContext, body: any, location: string | string[]): number;
|
29 | export declare function getResponse(context: HookContext): {
|
30 | status: number;
|
31 | headers: {
|
32 | [key: string]: string | string[];
|
33 | };
|
34 | body: any;
|
35 | };
|