Skip to main content
Full transcript of Integrate Didit in Your App: API, SDK and Webhooks (Developer Guide) - Didit Academy video 8 of 10, 08:13. Watch on YouTube. Each paragraph links to the exact moment in the video.

What you’ll wire up

00:04 In this video, you’ll get Dedit wired into your own app. So, your users verify right inside your product, and every result flows back to your system the moment it happens. This is the developers video, so it’s a little bit more technical, but it’s simpler than you think. And by the end, you’ll see you can hand most of it straight to cloud code and have it build it for you. So, we’ll go through it in order that

SDK, API and webhook: the three pieces

00:28 you’d actually build it. Let’s dive right in. Integrating Dedit means wiring up three things. The SDK renders the camera, the document capture, the NFC read, and the liveness UI right inside of your app. The API is server-to-server, so your back end creates the session and reads the authoritative decision. And the webhook calls your HTTPS endpoint the instant a session changes state, which is way

The integrate tab

00:56 faster and richer than polling for it. So, the easiest way to integrate is to go to your manage tab, click on integrate, and we can just grab all the settings from in here, so we can grab our API key. So, we could set up a specific API key for this particular app that we’re working on. We can create and choose a workflow that we want to integrate. We can add a webhook. So, this is where the verification results are pushed to. 01:24 And the signing secret, that I’ll show you in a second, this is what’s going to

Choosing your platform

01:28 go in your ENV file. You can then connect it to your app. So, we’ve got a few different options here. We’ve got web JS, React Native, iOS, Android, Flutter, and a few other surfaces here. So, you can select the one that is relevant for your app. This is the environment secrets that you’re going to put in your ENV file over on your

The AI setup prompt

01:48 server. So, the easy way to set this up would be to use the AI setup prompt. So, we configure all the settings up here, and then we copy the prompt and it’s going to copy all of the relevant information that we need from the setup that we’ve completed here. We copy and paste this, and we can pop that into Cloud Code or Codex or wherever you’re

API keys, one per environment

02:09 building your app. Your API keys live here, and each row has one key, okay? And so, a good habit is a separate key per environment per integration. So, you can rotate or revoke one without breaking the others. So, if you’re going to integrate a specific workflow, you

Creating a key

02:27 might want to just have a separate API key for that workflow, for example. Now, if I click create API key, um I’m just going to put test here, create the API key. Now, I can copy this, right? And I’m not going to see it again. So, it’s important that you copy it and maybe note it down somewhere so that you can use it when you’re doing the integration. When you come through to the integration section and you grab your API key, and let’s say if I grab the test key and I come down, I select, okay, we want to use this uh let’s see, KYC workflow. We can add a webhook. 03:05 We can connect our app, okay. And then we can pop in this setup prompt here. You can see here this prompt is going to

Webhooks overview

03:13 include the API key. So, moving on to webhooks real quick, we can set up a webhook for basically anything that we want. So, say if you want to send a specific event to Slack, right? We can

The documentation

03:25 add the webhook URL here. Okay, so let’s take a look at some of the documentation here cuz you do have access to all the technical documentation. If you just go to docs.didit.me, and we’re going to look at a few things

Create session: the one required field

03:37 in here. Everything revolves around the create session. All right, so this is a post request. This is the start of a verification. So, we could see here in the curl request, we got the workflow ID. This is the only required field, and the really useful bit is that this same endpoint creates both KYC and KYB sessions. The

Vendor data and callback URL

04:00 workflow is what decides which is which. So, we’ve got some additional fields down here, including the vendor data, which we’ve spoken about a lot in these videos. This is the unique identifier for each user, and you can define that as you wish, if it’s an email or a unique identifier, and then we have the callback URL here. This is where the user is going to get sent after they’ve completed the verification workflow. So,

Trying the endpoint live

04:24 if we scroll down here, we can actually try this out. So, if we click try it, we can actually create a verification session here. So, I’m just going to pop in one of the API keys here. Just going to create a brand new one, test two. I’ll copy that. Pop this in here. We want to grab a workflow ID. So, pop over to here. We can grab this workflow ID here. Enter that into there. The vendor data is not required. Let’s just do a a random string of numbers. 05:02 The callback, we can keep it the same here. None of this is required, by the way. I think this is because I have a test account here, but if you did want to test this endpoint, this is exactly how you would test it. Now, if you are a developer and you want specific answers here, you can check out the documentation. The MCP also has access to all of this documentation, so you can literally just integrate the MCP and ask Claude a question that you might have about something technical that’s probably going to be in these documents

Webhooks: why not polling

05:32 inside of here. So, let’s talk about webhooks. We do have a tab here in the manage section for webhooks, and this is how your results actually reach you. Webhooks are the recommended channel because polling is pretty slow, and it’s

Adding a destination and picking events

05:44 going to cost you more requests, and it’s going to skip events. So, we add a new destination in here. We can paste a URL. We can pick the events that we want. So, this is all the data that we want to send to this particular endpoint. And Diddy is going to hand you back a one-time signing secret, which I’ll show you in a second. And the URL has to be directly reachable. So, no localhost and no private IPs. So, I’m just going to come out of here and we can scroll over to the right-hand side and we can we’ve got a few options here. 06:16 So, we can see here the number of events this webhook is listening to and we can

The signing secret

06:19 copy the signing secret, which is going to be important for your integration. Now, when we do the setup the integration in the integrations tab, and I walked you through that we have a prompt, then the yeah, the signing secret is going to be in here for the webhook that you’ve selected in the setup. So,

The webhook handler prompt

06:34 another one of the ways that you can leverage AI, we’ve got a pre-made prompt here that I found in the webhooks tab here. We could see if you want to set up our webhook handler with AI. We can check out the documentation and we can find an integration prompt here. So, this is going to cover identity verification, entity, and transaction. It’s going to build it all out for you. So, it lays everything out. So, what to build, the signature headers of verification, the webhook event types that you just saw when we were setting up a webhook earlier. We’ve got the webhook envelope and a whole bunch more and we can also select where we want to paste it into, which tool that we’re using here. 07:15 So, if you want to use this prompt, that’s the easy way to get rolling with this and get your integrations set up. Everything I’ve just gone through in this video is accessible and queryable inside of your AI tool if you integrate the MCP server. So, you can just explain whatever you want to happen in plain English and Cloud Code will read the documentations and build the integration for you. So, you’re just checking the work, making sure it’s running and

Recap

07:41 working rather than coding everything from scratch. So, that’s Didit in your app. The SDK, your users see, the API that your back end calls, and the signed webhook that delivers the verdict that you build on. Trust the webhook, use vendor data everywhere, and lean on the setup prompt, so you’re not hand-wiring the boring parts. You can head to didit.me, sign up for free, and you can have a verification run in minutes.