Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
24 changes: 15 additions & 9 deletions apps/portal/src/app/bridge/webhooks/page.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import {
Callout,
OpenSourceCard,
createMetadata,
DocImage,
InstallTabs,
SDKCard,
Grid,
Expand All @@ -19,25 +20,31 @@ import {
UnrealEngineIcon,
} from "@/icons";

import BridgeWebhookScreen from "./assets/bridge-webhooks.png";

export const metadata = createMetadata({
image: {
title: "Payments Webhooks",
title: "Bridge Webhooks",
icon: "payments",
},
title: "Payments Webhooks",
description: "Learn how to set up and handle webhooks for thirdweb Payments transactions.",
title: "Bridge Webhooks",
description: "Learn how to set up and handle webhooks for thirdweb Bridge transactions.",
});

# Webhooks
# Bridge Webhooks

Create webhooks to be notified on each bridge, swap, and onramp transaction.

Create webhooks to be notified each time a payment is completed in your app.
## Dashboard

## Create a Webhook
You can create a webhook in your project dashboard by navigating to Bridge > Webhooks tab.

You can create a webhook in your project dashboard under the Webhooks > Bridge tab. You'll be prompted to copy a secret key before saving the webhook. This will be used for verification on all webhook requests received by your backend.
You'll be prompted to copy a secret key before saving the webhook. This will be used for verification on all webhook requests received by your backend.

<DocImage src={BridgeWebhookScreen} alt="Project Overview"/>

## Parse Webhook Payload with thirdweb SDK

## Parse Webhook Payload

The thirdweb SDK has a built-in function for parsing bridge webhook payloads

Expand Down Expand Up @@ -103,7 +110,6 @@ const payload = await Bridge.Webhook.parse(

```


## Example Payloads

<Tabs defaultValue="bridge">
Expand Down
4 changes: 4 additions & 0 deletions apps/portal/src/app/tokens/sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ export const sidebar: SideBar = {
],
name: "Deploy Tokens",
},
{
href: `${slug}/webhooks`,
name: "Webhooks",
},
],
name: "Guides",
},
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
30 changes: 30 additions & 0 deletions apps/portal/src/app/tokens/webhooks/page.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
import { DocImage} from "@doc"
import TokenWebhooksScreen from "./assets/token-webhooks.png"

# Webhooks

You can create webhooks to receive notifications for contract events such as token transfers or state changes or for blockchain transactions on any contract.

With webhooks, you'll receive event data in real-time without making constant requests, reducing RPC load and the risk of missing events.

## Use Cases

Your app may trigger an action when an onchain event occurs, such as:

- ETH or an ERC20 currency is transferred to or from a wallet.
- A token is minted from your NFT collection.
- A token in your NFT collection is burned or transferred.
- Metadata for an oracle contract is updated.

## Create Webhooks

You can configure token webhooks from the dashboard by navigating to your project and selecting Tokens > Webhooks

<DocImage src={TokenWebhooksScreen} alt="Token Webhooks Screen" />







2 changes: 1 addition & 1 deletion apps/portal/src/app/wallets/security/page.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ The response also arrives in the same payload format. We just perform the steps

## Wallets Audits

View the full audit reports for any wallets related features and specs:
View the full audit reports for any wallets-related features and specs:

- [7702 (Minimal Account)](https://0xmacro.com/library/audits/thirdweb-22)
- [Managed Account Factory](https://ipfs.io/ipfs/Qmc36VUCuwG2u7kZrqmXmJsH5c8sF7SHySVbPnwVmo3XYX/thirdweb%20A-14%20_%20Macro%20Audits%20_%20The%200xMacro%20Library.pdf)
Expand Down
19 changes: 0 additions & 19 deletions apps/portal/src/app/webhooks/layout.tsx

This file was deleted.

160 changes: 0 additions & 160 deletions apps/portal/src/app/webhooks/page.mdx

This file was deleted.

13 changes: 0 additions & 13 deletions apps/portal/src/app/webhooks/sidebar.tsx

This file was deleted.

Loading