@namera-ai/api 0.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +58 -0
- package/dist/common.js +13 -0
- package/dist/common.js.map +1 -0
- package/dist/index.d.ts +32 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +40 -0
- package/dist/index.js.map +1 -0
- package/dist/middlewares/admin.d.ts +25 -0
- package/dist/middlewares/admin.d.ts.map +1 -0
- package/dist/middlewares/admin.js +18 -0
- package/dist/middlewares/admin.js.map +1 -0
- package/dist/middlewares/auth.d.ts +640 -0
- package/dist/middlewares/auth.d.ts.map +1 -0
- package/dist/middlewares/auth.js +26 -0
- package/dist/middlewares/auth.js.map +1 -0
- package/dist/middlewares/index.d.ts +3 -0
- package/dist/routes/address-metadata.d.ts +147 -0
- package/dist/routes/address-metadata.d.ts.map +1 -0
- package/dist/routes/address-metadata.js +24 -0
- package/dist/routes/address-metadata.js.map +1 -0
- package/dist/routes/api-key.d.ts +864 -0
- package/dist/routes/api-key.d.ts.map +1 -0
- package/dist/routes/api-key.js +31 -0
- package/dist/routes/api-key.js.map +1 -0
- package/dist/routes/auth/core/index.d.ts +4 -0
- package/dist/routes/auth/core/magic-link.d.ts +34 -0
- package/dist/routes/auth/core/magic-link.d.ts.map +1 -0
- package/dist/routes/auth/core/magic-link.js +25 -0
- package/dist/routes/auth/core/magic-link.js.map +1 -0
- package/dist/routes/auth/core/session.d.ts +805 -0
- package/dist/routes/auth/core/session.d.ts.map +1 -0
- package/dist/routes/auth/core/session.js +31 -0
- package/dist/routes/auth/core/session.js.map +1 -0
- package/dist/routes/auth/core/user.d.ts +45 -0
- package/dist/routes/auth/core/user.d.ts.map +1 -0
- package/dist/routes/auth/core/user.js +15 -0
- package/dist/routes/auth/core/user.js.map +1 -0
- package/dist/routes/auth/index.d.ts +11 -0
- package/dist/routes/auth/notification.d.ts +392 -0
- package/dist/routes/auth/notification.d.ts.map +1 -0
- package/dist/routes/auth/notification.js +40 -0
- package/dist/routes/auth/notification.js.map +1 -0
- package/dist/routes/auth/oauth.d.ts +1347 -0
- package/dist/routes/auth/oauth.d.ts.map +1 -0
- package/dist/routes/auth/oauth.js +62 -0
- package/dist/routes/auth/oauth.js.map +1 -0
- package/dist/routes/auth/organization/index.d.ts +4 -0
- package/dist/routes/auth/organization/invitation.d.ts +400 -0
- package/dist/routes/auth/organization/invitation.d.ts.map +1 -0
- package/dist/routes/auth/organization/invitation.js +55 -0
- package/dist/routes/auth/organization/invitation.js.map +1 -0
- package/dist/routes/auth/organization/members.d.ts +250 -0
- package/dist/routes/auth/organization/members.d.ts.map +1 -0
- package/dist/routes/auth/organization/members.js +37 -0
- package/dist/routes/auth/organization/members.js.map +1 -0
- package/dist/routes/auth/organization/organization.d.ts +196 -0
- package/dist/routes/auth/organization/organization.d.ts.map +1 -0
- package/dist/routes/auth/organization/organization.js +31 -0
- package/dist/routes/auth/organization/organization.js.map +1 -0
- package/dist/routes/beta-invite.d.ts +24 -0
- package/dist/routes/beta-invite.d.ts.map +1 -0
- package/dist/routes/beta-invite.js +20 -0
- package/dist/routes/beta-invite.js.map +1 -0
- package/dist/routes/billing.d.ts +34 -0
- package/dist/routes/billing.d.ts.map +1 -0
- package/dist/routes/billing.js +14 -0
- package/dist/routes/billing.js.map +1 -0
- package/dist/routes/dashboard.d.ts +58 -0
- package/dist/routes/dashboard.d.ts.map +1 -0
- package/dist/routes/dashboard.js +14 -0
- package/dist/routes/dashboard.js.map +1 -0
- package/dist/routes/ens.d.ts +14 -0
- package/dist/routes/ens.d.ts.map +1 -0
- package/dist/routes/ens.js +15 -0
- package/dist/routes/ens.js.map +1 -0
- package/dist/routes/execution.d.ts +816 -0
- package/dist/routes/execution.d.ts.map +1 -0
- package/dist/routes/execution.js +50 -0
- package/dist/routes/execution.js.map +1 -0
- package/dist/routes/health.d.ts +10 -0
- package/dist/routes/health.d.ts.map +1 -0
- package/dist/routes/health.js +10 -0
- package/dist/routes/health.js.map +1 -0
- package/dist/routes/index.d.ts +23 -0
- package/dist/routes/portfolio.d.ts +94 -0
- package/dist/routes/portfolio.d.ts.map +1 -0
- package/dist/routes/portfolio.js +16 -0
- package/dist/routes/portfolio.js.map +1 -0
- package/dist/routes/session-key.d.ts +1844 -0
- package/dist/routes/session-key.d.ts.map +1 -0
- package/dist/routes/session-key.js +55 -0
- package/dist/routes/session-key.js.map +1 -0
- package/dist/routes/signature.d.ts +195 -0
- package/dist/routes/signature.d.ts.map +1 -0
- package/dist/routes/signature.js +38 -0
- package/dist/routes/signature.js.map +1 -0
- package/dist/routes/waitlist.d.ts +42 -0
- package/dist/routes/waitlist.d.ts.map +1 -0
- package/dist/routes/waitlist.js +27 -0
- package/dist/routes/waitlist.js.map +1 -0
- package/dist/routes/wallet.d.ts +547 -0
- package/dist/routes/wallet.d.ts.map +1 -0
- package/dist/routes/wallet.js +50 -0
- package/dist/routes/wallet.js.map +1 -0
- package/package.json +61 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"beta-invite.d.ts","names":[],"sources":["../../src/routes/beta-invite.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;cAQa,wBAAwB"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { CommonErrors } from "../common.js";
|
|
2
|
+
import { AdminAuthorization } from "../middlewares/admin.js";
|
|
3
|
+
import { HttpApiEndpoint, HttpApiGroup } from "effect/unstable/httpapi";
|
|
4
|
+
import { Schema } from "effect";
|
|
5
|
+
import { CreateBetaInvitesRequest, CreateBetaInvitesResponse } from "@namera-ai/protocol/dto";
|
|
6
|
+
|
|
7
|
+
//#region src/routes/beta-invite.ts
|
|
8
|
+
var BetaInviteGroup = class extends HttpApiGroup.make("betaInvite").add(HttpApiEndpoint.post("create", "/internal/invites", {
|
|
9
|
+
payload: CreateBetaInvitesRequest,
|
|
10
|
+
success: CreateBetaInvitesResponse,
|
|
11
|
+
error: CommonErrors
|
|
12
|
+
}), HttpApiEndpoint.delete("revoke", "/internal/invites/:id", {
|
|
13
|
+
params: { id: Schema.String.check(Schema.isUUID()) },
|
|
14
|
+
success: Schema.Struct({ revoked: Schema.Boolean }),
|
|
15
|
+
error: CommonErrors
|
|
16
|
+
})).middleware(AdminAuthorization) {};
|
|
17
|
+
|
|
18
|
+
//#endregion
|
|
19
|
+
export { BetaInviteGroup };
|
|
20
|
+
//# sourceMappingURL=beta-invite.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"beta-invite.js","names":[],"sources":["../../src/routes/beta-invite.ts"],"sourcesContent":["import { Schema } from \"effect\";\nimport { HttpApiEndpoint, HttpApiGroup } from \"effect/unstable/httpapi\";\n\nimport { CreateBetaInvitesRequest, CreateBetaInvitesResponse } from \"@namera-ai/protocol/dto\";\n\nimport { CommonErrors } from \"#/common\";\nimport { AdminAuthorization } from \"#/middlewares/admin\";\n\nexport class BetaInviteGroup extends HttpApiGroup.make(\"betaInvite\")\n .add(\n HttpApiEndpoint.post(\"create\", \"/internal/invites\", {\n payload: CreateBetaInvitesRequest,\n success: CreateBetaInvitesResponse,\n error: CommonErrors,\n }),\n HttpApiEndpoint.delete(\"revoke\", \"/internal/invites/:id\", {\n params: { id: Schema.String.check(Schema.isUUID()) },\n success: Schema.Struct({ revoked: Schema.Boolean }),\n error: CommonErrors,\n }),\n )\n .middleware(AdminAuthorization) {}\n"],"mappings":";;;;;;;AAQA,IAAa,kBAAb,cAAqC,aAAa,KAAK,YAAY,CAAC,CACjE,IACC,gBAAgB,KAAK,UAAU,qBAAqB;CAClD,SAAS;CACT,SAAS;CACT,OAAO;AACT,CAAC,GACD,gBAAgB,OAAO,UAAU,yBAAyB;CACxD,QAAQ,EAAE,IAAI,OAAO,OAAO,MAAM,OAAO,OAAO,CAAC,EAAE;CACnD,SAAS,OAAO,OAAO,EAAE,SAAS,OAAO,QAAQ,CAAC;CAClD,OAAO;AACT,CAAC,CACH,CAAC,CACA,WAAW,kBAAkB,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { Authorization } from "../middlewares/auth.js";
|
|
2
|
+
import "../middlewares/index.js";
|
|
3
|
+
import { HttpApiEndpoint, HttpApiGroup } from "effect/unstable/httpapi";
|
|
4
|
+
//#region src/routes/billing.d.ts
|
|
5
|
+
declare const BillingGroup_base: HttpApiGroup.HttpApiGroup<"billing", HttpApiEndpoint.HttpApiEndpoint<"get", "GET", "/billing", never, never, never, never, import("effect/Schema").toCodecJson<import("effect/Schema").Struct<{
|
|
6
|
+
readonly organizationId: import("effect/Schema").brand<import("effect/Schema").String, "OrganizationId">;
|
|
7
|
+
readonly plan: import("effect/Schema").Literals<readonly ["free", "pro", "business"]>;
|
|
8
|
+
readonly planVersion: import("effect/Schema").Int;
|
|
9
|
+
readonly status: import("effect/Schema").Literals<readonly ["trialing", "active", "past_due", "canceled", "ended"]>;
|
|
10
|
+
readonly period: import("effect/Schema").Struct<{
|
|
11
|
+
readonly id: import("effect/Schema").brand<import("effect/Schema").String, "BillingPeriodId">;
|
|
12
|
+
readonly startsAt: import("effect/Schema").DateTimeUtcFromDate;
|
|
13
|
+
readonly endsAt: import("effect/Schema").DateTimeUtcFromDate;
|
|
14
|
+
}>;
|
|
15
|
+
readonly resources: import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
16
|
+
readonly key: import("effect/Schema").Literals<readonly ["members", "software-wallets", "hsm-wallets", "local-wallets"]>;
|
|
17
|
+
readonly includedAmount: import("effect/Schema").BigIntFromString;
|
|
18
|
+
readonly usedAmount: import("effect/Schema").BigIntFromString;
|
|
19
|
+
readonly remainingAmount: import("effect/Schema").BigIntFromString;
|
|
20
|
+
}>>;
|
|
21
|
+
readonly meters: import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
22
|
+
readonly key: import("effect/Schema").Literals<readonly ["execution.mainnet", "execution.testnet", "signature", "gas-sponsorship"]>;
|
|
23
|
+
readonly unit: import("effect/Schema").Literals<readonly ["operation", "micro-usd"]>;
|
|
24
|
+
readonly includedAmount: import("effect/Schema").BigIntFromString;
|
|
25
|
+
readonly hardLimitAmount: import("effect/Schema").NullOr<import("effect/Schema").BigIntFromString>;
|
|
26
|
+
readonly consumedAmount: import("effect/Schema").BigIntFromString;
|
|
27
|
+
readonly reservedAmount: import("effect/Schema").BigIntFromString;
|
|
28
|
+
readonly remainingAmount: import("effect/Schema").NullOr<import("effect/Schema").BigIntFromString>;
|
|
29
|
+
}>>;
|
|
30
|
+
}>>, import("effect/Schema").toCodecJson<import("effect/unstable/httpapi/HttpApiSchema").asNoContent<typeof import("effect/unstable/httpapi/HttpApiError").Forbidden> | import("effect/unstable/httpapi/HttpApiSchema").asNoContent<typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError> | typeof import("@namera-ai/protocol").RateLimitExceeded>, Authorization, never>, false>;
|
|
31
|
+
declare class BillingGroup extends BillingGroup_base {}
|
|
32
|
+
//#endregion
|
|
33
|
+
export { BillingGroup };
|
|
34
|
+
//# sourceMappingURL=billing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"billing.d.ts","names":[],"sources":["../../src/routes/billing.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAOa,qBAAqB"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { CommonErrors } from "../common.js";
|
|
2
|
+
import { Authorization } from "../middlewares/auth.js";
|
|
3
|
+
import { HttpApiEndpoint, HttpApiGroup, OpenApi } from "effect/unstable/httpapi";
|
|
4
|
+
import { GetBillingResponse } from "@namera-ai/protocol/dto";
|
|
5
|
+
|
|
6
|
+
//#region src/routes/billing.ts
|
|
7
|
+
var BillingGroup = class extends HttpApiGroup.make("billing").add(HttpApiEndpoint.get("get", "/billing", {
|
|
8
|
+
success: GetBillingResponse,
|
|
9
|
+
error: CommonErrors
|
|
10
|
+
}).annotate(OpenApi.Summary, "Get the active billing period, entitlements, and meter balances")).annotate(OpenApi.Description, "Organization billing and entitlements").middleware(Authorization) {};
|
|
11
|
+
|
|
12
|
+
//#endregion
|
|
13
|
+
export { BillingGroup };
|
|
14
|
+
//# sourceMappingURL=billing.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"billing.js","names":[],"sources":["../../src/routes/billing.ts"],"sourcesContent":["import { HttpApiEndpoint, HttpApiGroup, OpenApi } from \"effect/unstable/httpapi\";\n\nimport { GetBillingResponse } from \"@namera-ai/protocol/dto\";\n\nimport { CommonErrors } from \"#/common\";\nimport { Authorization } from \"#/middlewares/index\";\n\nexport class BillingGroup extends HttpApiGroup.make(\"billing\")\n .add(\n HttpApiEndpoint.get(\"get\", \"/billing\", {\n success: GetBillingResponse,\n error: CommonErrors,\n }).annotate(OpenApi.Summary, \"Get the active billing period, entitlements, and meter balances\"),\n )\n .annotate(OpenApi.Description, \"Organization billing and entitlements\")\n .middleware(Authorization) {}\n"],"mappings":";;;;;;AAOA,IAAa,eAAb,cAAkC,aAAa,KAAK,SAAS,CAAC,CAC3D,IACC,gBAAgB,IAAI,OAAO,YAAY;CACrC,SAAS;CACT,OAAO;AACT,CAAC,CAAC,CAAC,SAAS,QAAQ,SAAS,iEAAiE,CAChG,CAAC,CACA,SAAS,QAAQ,aAAa,uCAAuC,CAAC,CACtE,WAAW,aAAa,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { Authorization } from "../middlewares/auth.js";
|
|
2
|
+
import "../middlewares/index.js";
|
|
3
|
+
import { HttpApiEndpoint, HttpApiGroup } from "effect/unstable/httpapi";
|
|
4
|
+
//#region src/routes/dashboard.d.ts
|
|
5
|
+
declare const DashboardGroup_base: HttpApiGroup.HttpApiGroup<"dashboard", HttpApiEndpoint.HttpApiEndpoint<"getOverview", "GET", "/dashboard/overview", never, never, never, never, import("effect/Schema").toCodecJson<import("effect/Schema").Struct<{
|
|
6
|
+
readonly organizationId: import("effect/Schema").brand<import("effect/Schema").String, "OrganizationId">;
|
|
7
|
+
readonly resources: import("effect/Schema").Struct<{
|
|
8
|
+
readonly accounts: import("effect/Schema").Struct<{
|
|
9
|
+
readonly total: import("effect/Schema").Int;
|
|
10
|
+
readonly active: import("effect/Schema").Int;
|
|
11
|
+
}>;
|
|
12
|
+
readonly sessionKeys: import("effect/Schema").Struct<{
|
|
13
|
+
readonly total: import("effect/Schema").Int;
|
|
14
|
+
readonly active: import("effect/Schema").Int;
|
|
15
|
+
}>;
|
|
16
|
+
}>;
|
|
17
|
+
readonly namespaces: import("effect/Schema").$Array<import("effect/Schema").Union<readonly [import("effect/Schema").Struct<{
|
|
18
|
+
readonly namespace: import("effect/Schema").Literal<"eip155">;
|
|
19
|
+
readonly totals: import("effect/Schema").Struct<{
|
|
20
|
+
readonly executions: import("effect/Schema").BigIntFromString;
|
|
21
|
+
readonly signatures: import("effect/Schema").BigIntFromString;
|
|
22
|
+
}>;
|
|
23
|
+
readonly activity: import("effect/Schema").Struct<{
|
|
24
|
+
readonly daily: import("effect/Schema").Struct<{
|
|
25
|
+
readonly granularity: import("effect/Schema").Literals<readonly ["day", "week", "month"]>;
|
|
26
|
+
readonly points: import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
27
|
+
readonly date: import("effect/Schema").String;
|
|
28
|
+
readonly executions: import("effect/Schema").Int;
|
|
29
|
+
readonly signatures: import("effect/Schema").Int;
|
|
30
|
+
}>>;
|
|
31
|
+
}>;
|
|
32
|
+
readonly weekly: import("effect/Schema").Struct<{
|
|
33
|
+
readonly granularity: import("effect/Schema").Literals<readonly ["day", "week", "month"]>;
|
|
34
|
+
readonly points: import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
35
|
+
readonly date: import("effect/Schema").String;
|
|
36
|
+
readonly executions: import("effect/Schema").Int;
|
|
37
|
+
readonly signatures: import("effect/Schema").Int;
|
|
38
|
+
}>>;
|
|
39
|
+
}>;
|
|
40
|
+
readonly monthly: import("effect/Schema").Struct<{
|
|
41
|
+
readonly granularity: import("effect/Schema").Literals<readonly ["day", "week", "month"]>;
|
|
42
|
+
readonly points: import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
43
|
+
readonly date: import("effect/Schema").String;
|
|
44
|
+
readonly executions: import("effect/Schema").Int;
|
|
45
|
+
readonly signatures: import("effect/Schema").Int;
|
|
46
|
+
}>>;
|
|
47
|
+
}>;
|
|
48
|
+
}>;
|
|
49
|
+
readonly executionSources: import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
50
|
+
readonly actorType: import("effect/Schema").Literals<readonly ["user", "api-key", "mcp", "cli"]>;
|
|
51
|
+
readonly count: import("effect/Schema").Int;
|
|
52
|
+
}>>;
|
|
53
|
+
}>]>>;
|
|
54
|
+
}>>, import("effect/Schema").toCodecJson<import("effect/unstable/httpapi/HttpApiSchema").asNoContent<typeof import("effect/unstable/httpapi/HttpApiError").Forbidden> | import("effect/unstable/httpapi/HttpApiSchema").asNoContent<typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError> | typeof import("@namera-ai/protocol").RateLimitExceeded>, Authorization, never>, false>;
|
|
55
|
+
declare class DashboardGroup extends DashboardGroup_base {}
|
|
56
|
+
//#endregion
|
|
57
|
+
export { DashboardGroup };
|
|
58
|
+
//# sourceMappingURL=dashboard.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dashboard.d.ts","names":[],"sources":["../../src/routes/dashboard.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAOa,uBAAuB"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { CommonErrors } from "../common.js";
|
|
2
|
+
import { Authorization } from "../middlewares/auth.js";
|
|
3
|
+
import { HttpApiEndpoint, HttpApiGroup, OpenApi } from "effect/unstable/httpapi";
|
|
4
|
+
import { GetDashboardOverviewResponse } from "@namera-ai/protocol/dto";
|
|
5
|
+
|
|
6
|
+
//#region src/routes/dashboard.ts
|
|
7
|
+
var DashboardGroup = class extends HttpApiGroup.make("dashboard").add(HttpApiEndpoint.get("getOverview", "/dashboard/overview", {
|
|
8
|
+
success: GetDashboardOverviewResponse,
|
|
9
|
+
error: CommonErrors
|
|
10
|
+
}).annotate(OpenApi.Summary, "Get the active organization's operational overview")).annotate(OpenApi.Description, "Organization dashboard projections").middleware(Authorization) {};
|
|
11
|
+
|
|
12
|
+
//#endregion
|
|
13
|
+
export { DashboardGroup };
|
|
14
|
+
//# sourceMappingURL=dashboard.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dashboard.js","names":[],"sources":["../../src/routes/dashboard.ts"],"sourcesContent":["import { HttpApiEndpoint, HttpApiGroup, OpenApi } from \"effect/unstable/httpapi\";\n\nimport { GetDashboardOverviewResponse } from \"@namera-ai/protocol/dto\";\n\nimport { CommonErrors } from \"#/common\";\nimport { Authorization } from \"#/middlewares/index\";\n\nexport class DashboardGroup extends HttpApiGroup.make(\"dashboard\")\n .add(\n HttpApiEndpoint.get(\"getOverview\", \"/dashboard/overview\", {\n success: GetDashboardOverviewResponse,\n error: CommonErrors,\n }).annotate(OpenApi.Summary, \"Get the active organization's operational overview\"),\n )\n .annotate(OpenApi.Description, \"Organization dashboard projections\")\n .middleware(Authorization) {}\n"],"mappings":";;;;;;AAOA,IAAa,iBAAb,cAAoC,aAAa,KAAK,WAAW,CAAC,CAC/D,IACC,gBAAgB,IAAI,eAAe,uBAAuB;CACxD,SAAS;CACT,OAAO;AACT,CAAC,CAAC,CAAC,SAAS,QAAQ,SAAS,oDAAoD,CACnF,CAAC,CACA,SAAS,QAAQ,aAAa,oCAAoC,CAAC,CACnE,WAAW,aAAa,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { HttpApiEndpoint, HttpApiGroup } from "effect/unstable/httpapi";
|
|
2
|
+
import { EnsUnavailableError } from "@namera-ai/protocol";
|
|
3
|
+
//#region src/routes/ens.d.ts
|
|
4
|
+
declare const EnsGroup_base: HttpApiGroup.HttpApiGroup<"ens", HttpApiEndpoint.HttpApiEndpoint<"isNameAvailable", "GET", "/ens/availability", never, import("effect/Schema").toCodecStringTree<import("effect/Schema").Struct<{
|
|
5
|
+
readonly label: import("effect/Schema").decodeTo<import("effect/Schema").String, import("effect/Schema").String, never, never>;
|
|
6
|
+
}>>, never, never, import("effect/Schema").toCodecJson<import("effect/Schema").Struct<{
|
|
7
|
+
readonly label: import("effect/Schema").decodeTo<import("effect/Schema").String, import("effect/Schema").String, never, never>;
|
|
8
|
+
readonly name: import("effect/Schema").String;
|
|
9
|
+
readonly available: import("effect/Schema").Boolean;
|
|
10
|
+
}>>, import("effect/Schema").toCodecJson<import("effect/unstable/httpapi/HttpApiSchema").asNoContent<typeof import("effect/unstable/httpapi/HttpApiError").Forbidden> | import("effect/unstable/httpapi/HttpApiSchema").asNoContent<typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError> | typeof import("@namera-ai/protocol").RateLimitExceeded | typeof EnsUnavailableError>, never, never>, false>;
|
|
11
|
+
declare class EnsGroup extends EnsGroup_base {}
|
|
12
|
+
//#endregion
|
|
13
|
+
export { EnsGroup };
|
|
14
|
+
//# sourceMappingURL=ens.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ens.d.ts","names":[],"sources":["../../src/routes/ens.ts"],"mappings":";;;;;;;;;;cAOa,iBAAiB"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { CommonErrors } from "../common.js";
|
|
2
|
+
import { HttpApiEndpoint, HttpApiGroup, OpenApi } from "effect/unstable/httpapi";
|
|
3
|
+
import { EnsUnavailableError } from "@namera-ai/protocol";
|
|
4
|
+
import { EnsNameAvailabilityRequest, EnsNameAvailabilityResponse } from "@namera-ai/protocol/dto";
|
|
5
|
+
|
|
6
|
+
//#region src/routes/ens.ts
|
|
7
|
+
var EnsGroup = class extends HttpApiGroup.make("ens").add(HttpApiEndpoint.get("isNameAvailable", "/availability", {
|
|
8
|
+
query: EnsNameAvailabilityRequest,
|
|
9
|
+
success: EnsNameAvailabilityResponse,
|
|
10
|
+
error: [EnsUnavailableError, ...CommonErrors]
|
|
11
|
+
}).annotate(OpenApi.Summary, "Check whether a Namera ENS label is available")).annotate(OpenApi.Description, "Public ENS name availability").prefix("/ens") {};
|
|
12
|
+
|
|
13
|
+
//#endregion
|
|
14
|
+
export { EnsGroup };
|
|
15
|
+
//# sourceMappingURL=ens.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ens.js","names":[],"sources":["../../src/routes/ens.ts"],"sourcesContent":["import { HttpApiEndpoint, HttpApiGroup, OpenApi } from \"effect/unstable/httpapi\";\n\nimport { EnsUnavailableError } from \"@namera-ai/protocol\";\nimport { EnsNameAvailabilityRequest, EnsNameAvailabilityResponse } from \"@namera-ai/protocol/dto\";\n\nimport { CommonErrors } from \"#/common\";\n\nexport class EnsGroup extends HttpApiGroup.make(\"ens\")\n .add(\n HttpApiEndpoint.get(\"isNameAvailable\", \"/availability\", {\n query: EnsNameAvailabilityRequest,\n success: EnsNameAvailabilityResponse,\n error: [EnsUnavailableError, ...CommonErrors],\n }).annotate(OpenApi.Summary, \"Check whether a Namera ENS label is available\"),\n )\n .annotate(OpenApi.Description, \"Public ENS name availability\")\n .prefix(\"/ens\") {}\n"],"mappings":";;;;;;AAOA,IAAa,WAAb,cAA8B,aAAa,KAAK,KAAK,CAAC,CACnD,IACC,gBAAgB,IAAI,mBAAmB,iBAAiB;CACtD,OAAO;CACP,SAAS;CACT,OAAO,CAAC,qBAAqB,GAAG,YAAY;AAC9C,CAAC,CAAC,CAAC,SAAS,QAAQ,SAAS,+CAA+C,CAC9E,CAAC,CACA,SAAS,QAAQ,aAAa,8BAA8B,CAAC,CAC7D,OAAO,MAAM,CAAC,CAAC,CAAC"}
|