Add webhook calls ui

Signed-off-by: Sacha Al Himdani <sacha@getprobo.com>
This commit is contained in:
Sacha Al Himdani
2026-02-12 17:09:40 +01:00
parent f9de9c4834
commit a345e0be02
11 changed files with 1925 additions and 5 deletions

View File

@@ -1,5 +1,5 @@
/**
* @generated SignedSource<<ddaaa2d60cc045e841daaa3be6428cf2>>
* @generated SignedSource<<cc57c5db0d6374e4941bb0d4f1fb73c2>>
* @lightSyntaxTransform
* @nogrep
*/
@@ -20,6 +20,9 @@ export type WebhooksSettingsPageQuery$data = {
readonly webhookConfigurations: {
readonly edges: ReadonlyArray<{
readonly node: {
readonly calls: {
readonly totalCount: number;
};
readonly endpointUrl: string;
readonly id: string;
readonly selectedEvents: ReadonlyArray<WebhookEventType>;
@@ -98,6 +101,30 @@ v4 = [
"name": "selectedEvents",
"storageKey": null
},
{
"alias": null,
"args": [
{
"kind": "Literal",
"name": "first",
"value": 0
}
],
"concreteType": "WebhookCallConnection",
"kind": "LinkedField",
"name": "calls",
"plural": false,
"selections": [
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "totalCount",
"storageKey": null
}
],
"storageKey": "calls(first:0)"
},
(v2/*: any*/)
],
"storageKey": null
@@ -238,7 +265,7 @@ return {
]
},
"params": {
"cacheID": "e6aa5c6b8142b654e2a3b7bebec59f83",
"cacheID": "97b7c454586fe958e456fa7929b46686",
"id": null,
"metadata": {
"connection": [
@@ -255,11 +282,11 @@ return {
},
"name": "WebhooksSettingsPageQuery",
"operationKind": "query",
"text": "query WebhooksSettingsPageQuery(\n $organizationId: ID!\n) {\n organization: node(id: $organizationId) {\n __typename\n ... on Organization {\n id\n webhookConfigurations(first: 50) {\n edges {\n node {\n id\n endpointUrl\n selectedEvents\n __typename\n }\n cursor\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n }\n id\n }\n}\n"
"text": "query WebhooksSettingsPageQuery(\n $organizationId: ID!\n) {\n organization: node(id: $organizationId) {\n __typename\n ... on Organization {\n id\n webhookConfigurations(first: 50) {\n edges {\n node {\n id\n endpointUrl\n selectedEvents\n calls(first: 0) {\n totalCount\n }\n __typename\n }\n cursor\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n }\n id\n }\n}\n"
}
};
})();
(node as any).hash = "2a68dcb3a875a982b7d8300aa72c012b";
(node as any).hash = "58012f55644dae31fe5e18c2c1e193a7";
export default node;

View File

@@ -0,0 +1,257 @@
/**
* @generated SignedSource<<c53381e72c0d17cff70568af0bbbb6e5>>
* @lightSyntaxTransform
* @nogrep
*/
/* tslint:disable */
/* eslint-disable */
// @ts-nocheck
import { ConcreteRequest } from 'relay-runtime';
export type WebhookCallStatus = "FAILED" | "SUCCEEDED";
export type WebhooksSettingsPage_callsQuery$variables = {
after?: string | null | undefined;
first?: number | null | undefined;
webhookConfigurationId: string;
};
export type WebhooksSettingsPage_callsQuery$data = {
readonly node: {
readonly calls?: {
readonly edges: ReadonlyArray<{
readonly node: {
readonly createdAt: string;
readonly endpointUrl: string;
readonly id: string;
readonly response: string | null | undefined;
readonly status: WebhookCallStatus;
};
}>;
readonly pageInfo: {
readonly endCursor: string | null | undefined;
readonly hasNextPage: boolean;
};
readonly totalCount: number;
};
};
};
export type WebhooksSettingsPage_callsQuery = {
response: WebhooksSettingsPage_callsQuery$data;
variables: WebhooksSettingsPage_callsQuery$variables;
};
const node: ConcreteRequest = (function(){
var v0 = {
"defaultValue": null,
"kind": "LocalArgument",
"name": "after"
},
v1 = {
"defaultValue": null,
"kind": "LocalArgument",
"name": "first"
},
v2 = {
"defaultValue": null,
"kind": "LocalArgument",
"name": "webhookConfigurationId"
},
v3 = [
{
"kind": "Variable",
"name": "id",
"variableName": "webhookConfigurationId"
}
],
v4 = {
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "id",
"storageKey": null
},
v5 = {
"kind": "InlineFragment",
"selections": [
{
"alias": null,
"args": [
{
"kind": "Variable",
"name": "after",
"variableName": "after"
},
{
"kind": "Variable",
"name": "first",
"variableName": "first"
}
],
"concreteType": "WebhookCallConnection",
"kind": "LinkedField",
"name": "calls",
"plural": false,
"selections": [
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "totalCount",
"storageKey": null
},
{
"alias": null,
"args": null,
"concreteType": "PageInfo",
"kind": "LinkedField",
"name": "pageInfo",
"plural": false,
"selections": [
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "hasNextPage",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "endCursor",
"storageKey": null
}
],
"storageKey": null
},
{
"alias": null,
"args": null,
"concreteType": "WebhookCallEdge",
"kind": "LinkedField",
"name": "edges",
"plural": true,
"selections": [
{
"alias": null,
"args": null,
"concreteType": "WebhookCall",
"kind": "LinkedField",
"name": "node",
"plural": false,
"selections": [
(v4/*: any*/),
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "status",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "endpointUrl",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "createdAt",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "response",
"storageKey": null
}
],
"storageKey": null
}
],
"storageKey": null
}
],
"storageKey": null
}
],
"type": "WebhookConfiguration",
"abstractKey": null
};
return {
"fragment": {
"argumentDefinitions": [
(v0/*: any*/),
(v1/*: any*/),
(v2/*: any*/)
],
"kind": "Fragment",
"metadata": null,
"name": "WebhooksSettingsPage_callsQuery",
"selections": [
{
"alias": null,
"args": (v3/*: any*/),
"concreteType": null,
"kind": "LinkedField",
"name": "node",
"plural": false,
"selections": [
(v5/*: any*/)
],
"storageKey": null
}
],
"type": "Query",
"abstractKey": null
},
"kind": "Request",
"operation": {
"argumentDefinitions": [
(v2/*: any*/),
(v1/*: any*/),
(v0/*: any*/)
],
"kind": "Operation",
"name": "WebhooksSettingsPage_callsQuery",
"selections": [
{
"alias": null,
"args": (v3/*: any*/),
"concreteType": null,
"kind": "LinkedField",
"name": "node",
"plural": false,
"selections": [
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "__typename",
"storageKey": null
},
(v5/*: any*/),
(v4/*: any*/)
],
"storageKey": null
}
]
},
"params": {
"cacheID": "9371a8918daebbb2a660b02649ba0241",
"id": null,
"metadata": {},
"name": "WebhooksSettingsPage_callsQuery",
"operationKind": "query",
"text": "query WebhooksSettingsPage_callsQuery(\n $webhookConfigurationId: ID!\n $first: Int\n $after: CursorKey\n) {\n node(id: $webhookConfigurationId) {\n __typename\n ... on WebhookConfiguration {\n calls(first: $first, after: $after) {\n totalCount\n pageInfo {\n hasNextPage\n endCursor\n }\n edges {\n node {\n id\n status\n endpointUrl\n createdAt\n response\n }\n }\n }\n }\n id\n }\n}\n"
}
};
})();
(node as any).hash = "de18874117b6272fdf2e22871adc4a5d";
export default node;