@automate.ax/api-contract 0.139.1 → 0.141.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/dist/events/index.d.ts +11 -0
- package/dist/events/index.js +2 -0
- package/dist/events/meta-ads.d.ts +14 -0
- package/dist/events/meta-ads.js +17 -0
- package/dist/index.d.ts +11 -0
- package/package.json +3 -3
- package/src/events/index.ts +2 -0
- package/src/events/meta-ads.ts +18 -0
package/dist/events/index.d.ts
CHANGED
|
@@ -3563,6 +3563,17 @@ export declare const eventsContract: {
|
|
|
3563
3563
|
type: "bot";
|
|
3564
3564
|
})[] | undefined;
|
|
3565
3565
|
}>>]>, import("zod").ZodObject<{}, import("zod/v4/core").$strip>, Record<never, never>, Record<never, never>>;
|
|
3566
|
+
metaAdsEvent: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
3567
|
+
entry: import("zod").ZodArray<import("zod").ZodObject<{
|
|
3568
|
+
changes: import("zod").ZodArray<import("zod").ZodObject<{
|
|
3569
|
+
field: import("zod").ZodString;
|
|
3570
|
+
value: import("zod").ZodOptional<import("zod").ZodCustom<import("@automate.ax/codec").Encodable, import("@automate.ax/codec").Encodable>>;
|
|
3571
|
+
}, import("zod/v4/core").$strip>>;
|
|
3572
|
+
id: import("zod").ZodString;
|
|
3573
|
+
time: import("zod").ZodNumber;
|
|
3574
|
+
}, import("zod/v4/core").$strip>>;
|
|
3575
|
+
object: import("zod").ZodString;
|
|
3576
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodVoid, Record<never, never>, Record<never, never>>;
|
|
3566
3577
|
microsoftGraphNotification: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
3567
3578
|
sourceId: import("zod").ZodString;
|
|
3568
3579
|
value: import("zod").ZodArray<import("zod").ZodObject<{
|
package/dist/events/index.js
CHANGED
|
@@ -18,6 +18,7 @@ import { linearEventsContract } from "./linear.js";
|
|
|
18
18
|
import { millionVerifierEventsContract } from "./millionverifier.js";
|
|
19
19
|
import { mailhookEventsContract } from "./mailhook.js";
|
|
20
20
|
import { microsoftEventsContract } from "./microsoft.js";
|
|
21
|
+
import { metaAdsEventsContract } from "./meta-ads.js";
|
|
21
22
|
import { notionEventsContract } from "./notion.js";
|
|
22
23
|
import { resendEventsContract } from "./resend.js";
|
|
23
24
|
import { slackEventsContract } from "./slack.js";
|
|
@@ -47,6 +48,7 @@ export const eventsContract = {
|
|
|
47
48
|
...millionVerifierEventsContract,
|
|
48
49
|
...mailhookEventsContract,
|
|
49
50
|
...microsoftEventsContract,
|
|
51
|
+
...metaAdsEventsContract,
|
|
50
52
|
...notionEventsContract,
|
|
51
53
|
...resendEventsContract,
|
|
52
54
|
...slackEventsContract,
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as z from "zod";
|
|
2
|
+
export declare const metaAdsEventsContract: {
|
|
3
|
+
metaAdsEvent: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<z.ZodObject<{
|
|
4
|
+
entry: z.ZodArray<z.ZodObject<{
|
|
5
|
+
changes: z.ZodArray<z.ZodObject<{
|
|
6
|
+
field: z.ZodString;
|
|
7
|
+
value: z.ZodOptional<z.ZodCustom<import("@automate.ax/codec").Encodable, import("@automate.ax/codec").Encodable>>;
|
|
8
|
+
}, z.core.$strip>>;
|
|
9
|
+
id: z.ZodString;
|
|
10
|
+
time: z.ZodNumber;
|
|
11
|
+
}, z.core.$strip>>;
|
|
12
|
+
object: z.ZodString;
|
|
13
|
+
}, z.core.$strip>, z.ZodVoid, Record<never, never>, Record<never, never>>;
|
|
14
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { META_ADS_WEBHOOK_ENVELOPE_SCHEMA } from "@automate.ax/integration-contracts/meta-ads";
|
|
2
|
+
import { oc } from "@orpc/contract";
|
|
3
|
+
import * as z from "zod";
|
|
4
|
+
export const metaAdsEventsContract = {
|
|
5
|
+
metaAdsEvent: oc
|
|
6
|
+
.route({
|
|
7
|
+
description: "Receives and authenticates Meta Ads and Lead Ads webhooks.",
|
|
8
|
+
method: "POST",
|
|
9
|
+
operationId: "receiveMetaAdsEvent",
|
|
10
|
+
path: "/events/meta-ads",
|
|
11
|
+
successStatus: 200,
|
|
12
|
+
summary: "Receive a Meta Ads event",
|
|
13
|
+
tags: ["Events"],
|
|
14
|
+
})
|
|
15
|
+
.input(META_ADS_WEBHOOK_ENVELOPE_SCHEMA)
|
|
16
|
+
.output(z.void()),
|
|
17
|
+
};
|
package/dist/index.d.ts
CHANGED
|
@@ -5829,6 +5829,17 @@ export declare const contract: {
|
|
|
5829
5829
|
type: "bot";
|
|
5830
5830
|
})[] | undefined;
|
|
5831
5831
|
}>>]>, import("zod").ZodObject<{}, import("zod/v4/core").$strip>, Record<never, never>, Record<never, never>>;
|
|
5832
|
+
metaAdsEvent: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
5833
|
+
entry: import("zod").ZodArray<import("zod").ZodObject<{
|
|
5834
|
+
changes: import("zod").ZodArray<import("zod").ZodObject<{
|
|
5835
|
+
field: import("zod").ZodString;
|
|
5836
|
+
value: import("zod").ZodOptional<import("zod").ZodCustom<import("@automate.ax/codec").Encodable, import("@automate.ax/codec").Encodable>>;
|
|
5837
|
+
}, import("zod/v4/core").$strip>>;
|
|
5838
|
+
id: import("zod").ZodString;
|
|
5839
|
+
time: import("zod").ZodNumber;
|
|
5840
|
+
}, import("zod/v4/core").$strip>>;
|
|
5841
|
+
object: import("zod").ZodString;
|
|
5842
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodVoid, Record<never, never>, Record<never, never>>;
|
|
5832
5843
|
microsoftGraphNotification: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
5833
5844
|
sourceId: import("zod").ZodString;
|
|
5834
5845
|
value: import("zod").ZodArray<import("zod").ZodObject<{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@automate.ax/api-contract",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.141.0",
|
|
4
4
|
"description": "Public oRPC contract for the Automate.ax API.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -31,8 +31,8 @@
|
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
33
|
"@ai-sdk/gateway": "4.0.46",
|
|
34
|
-
"@automate.ax/codec": "0.
|
|
35
|
-
"@automate.ax/integration-contracts": "0.
|
|
34
|
+
"@automate.ax/codec": "0.141.0",
|
|
35
|
+
"@automate.ax/integration-contracts": "0.141.0",
|
|
36
36
|
"@orpc/contract": "1.15.0",
|
|
37
37
|
"fast-json-stable-stringify": "^2.1.0",
|
|
38
38
|
"zod": "^4.3.6"
|
package/src/events/index.ts
CHANGED
|
@@ -18,6 +18,7 @@ import { linearEventsContract } from "./linear"
|
|
|
18
18
|
import { millionVerifierEventsContract } from "./millionverifier"
|
|
19
19
|
import { mailhookEventsContract } from "./mailhook"
|
|
20
20
|
import { microsoftEventsContract } from "./microsoft"
|
|
21
|
+
import { metaAdsEventsContract } from "./meta-ads"
|
|
21
22
|
import { notionEventsContract } from "./notion"
|
|
22
23
|
import { resendEventsContract } from "./resend"
|
|
23
24
|
import { slackEventsContract } from "./slack"
|
|
@@ -48,6 +49,7 @@ export const eventsContract = {
|
|
|
48
49
|
...millionVerifierEventsContract,
|
|
49
50
|
...mailhookEventsContract,
|
|
50
51
|
...microsoftEventsContract,
|
|
52
|
+
...metaAdsEventsContract,
|
|
51
53
|
...notionEventsContract,
|
|
52
54
|
...resendEventsContract,
|
|
53
55
|
...slackEventsContract,
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { META_ADS_WEBHOOK_ENVELOPE_SCHEMA } from "@automate.ax/integration-contracts/meta-ads"
|
|
2
|
+
import { oc } from "@orpc/contract"
|
|
3
|
+
import * as z from "zod"
|
|
4
|
+
|
|
5
|
+
export const metaAdsEventsContract = {
|
|
6
|
+
metaAdsEvent: oc
|
|
7
|
+
.route({
|
|
8
|
+
description: "Receives and authenticates Meta Ads and Lead Ads webhooks.",
|
|
9
|
+
method: "POST",
|
|
10
|
+
operationId: "receiveMetaAdsEvent",
|
|
11
|
+
path: "/events/meta-ads",
|
|
12
|
+
successStatus: 200,
|
|
13
|
+
summary: "Receive a Meta Ads event",
|
|
14
|
+
tags: ["Events"],
|
|
15
|
+
})
|
|
16
|
+
.input(META_ADS_WEBHOOK_ENVELOPE_SCHEMA)
|
|
17
|
+
.output(z.void()),
|
|
18
|
+
}
|