Skip to content

Commit 55c073d

Browse files
Mermaid diagrams from images (#124)
* account creation diagram * customization diagrams * image ref * webhook diagram and title * medium gray for light and dark mode * titles --------- Co-authored-by: Atul-Butola <[email protected]>
1 parent d69f7ff commit 55c073d

12 files changed

+103
-11
lines changed
-85.1 KB
Binary file not shown.
-66.4 KB
Binary file not shown.
-151 KB
Binary file not shown.

fern/docs/img/diagram_4.png

-293 KB
Binary file not shown.

fern/docs/img/mermaid.png

-31.1 KB
Binary file not shown.

fern/docs/pages/adaas/extraction-phases.mdx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,13 @@ of the snap-in.
77

88
```mermaid
99
sequenceDiagram
10-
%%{init: { "fontFamily": "Segoe UI" } }%%
10+
%%{init: {
11+
'theme': 'base',
12+
'themeVariables': {
13+
'fontFamily': 'Segoe UI',
14+
'signalColor': '#7d7f7c',
15+
'signalTextColor': '#7d7f7c'
16+
}}}%%
1117
actor user as User
1218
participant gw as REST API Gateway
1319
participant ad as Airdrop components

fern/docs/pages/adaas/overview.mdx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,12 @@ It enables developers to create external workers (extractors and loaders) to bri
99

1010
```mermaid
1111
flowchart TD
12-
%%{init: { "fontFamily": "Segoe UI" } }%%
12+
%%{init: {
13+
'theme': 'base',
14+
'themeVariables': {
15+
'fontFamily': 'Segoe UI',
16+
'lineColor': '#7d7f7c'
17+
}}}%%
1318
externalSystem[External system]
1419
worker([Worker])
1520
s3interact[s3interact]

fern/docs/pages/create-accounts.mdx

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,29 @@ The `rev-users.create` API is used to create [contacts](https://docs.devrev.ai/p
88
Just want to get a token and get started? This [tutorial](/about/authentication#generate-a-personal-access-token-pat) teaches you the fastest way to get a token.
99
</Callout>
1010

11-
![mermaid-diagram](../img/mermaid.png)
11+
```mermaid
12+
flowchart TD
13+
%%{init: {
14+
'theme': 'base',
15+
'themeVariables': {
16+
'fontFamily': 'Segoe UI',
17+
'lineColor': '#7d7f7c'
18+
}}}%%
19+
acct-create[accounts.create]
20+
exist(((Account is existing
21+
'account ID')))
22+
list[rev-orgs.list with
23+
'account' filter]
24+
get[rev-orgs.get with
25+
'account ID']
26+
display(((Get rev-org 'display_id')))
27+
rev-user-create[Create a 'rev-user' under 'contact']
28+
acct-create --> exist -->|Yes|get
29+
exist -->|No|list
30+
get --> display
31+
list --> display
32+
display --> rev-user-create
33+
```
1234

1335
## Create an account
1436

fern/docs/pages/customization.mdx

Lines changed: 45 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,23 @@ field in the old fragment points to the new fragment.
288288
The diagram below shows the relationship between the fragments and how the versioning
289289
scheme preserves the referential integrity.
290290

291-
![Fragment Versioning](../img/customization-versioning.png)
291+
```mermaid Fragment versioning
292+
flowchart LR
293+
%%{init: {
294+
'theme': 'base',
295+
'themeVariables': {
296+
'fontFamily': 'Segoe UI',
297+
'lineColor': '#7d7f7c'
298+
}}}%%
299+
subgraph Versions
300+
v1[Fragment v1]
301+
v2[Fragment v2]
302+
v1 --> v2
303+
end
304+
o1[Object 1] -.-> v1
305+
o2[Object 2] -.-> v1
306+
o3[Object 3] -.-> v2
307+
```
292308

293309
### Object upgrades
294310

@@ -453,7 +469,16 @@ instead.
453469
Stages represent the different phases an object can be in during its lifecycle. For
454470
example, an issue might go through the following lifecycle:
455471

456-
![Issue Lifecycle](../img/customization-stage-transition.png)
472+
```mermaid Issue stages
473+
flowchart LR
474+
%%{init: {
475+
'theme': 'base',
476+
'themeVariables': {
477+
'fontFamily': 'Segoe UI',
478+
'lineColor': '#7d7f7c'
479+
}}}%%
480+
Backlog --> dev[In development] --> Completed
481+
```
457482

458483
Customizing the stages allows you to tailor the object lifecycle to your organization's
459484
specific requirements.
@@ -491,7 +516,24 @@ For example, _triage_ stage can transition to _backlog_ stage but not vice versa
491516

492517
Let's create a stage diagram for the _bug_ subtype:
493518

494-
![Stage Diagram](../img/customization-stage-diagram.png)
519+
```mermaid Bug stages
520+
flowchart LR
521+
%%{init: {
522+
'theme': 'base',
523+
'themeVariables': {
524+
'fontFamily': 'Segoe UI',
525+
'lineColor': '#7d7f7c'
526+
}}}%%
527+
backl[**Backlog**
528+
don:core:dvrv-us-1:devo/11FVC3ScK:stage/1]
529+
dev[**In development**
530+
don:core:dvrv-us-1:devo/11FVC3ScK:stage/2]
531+
rca[**Needs RCA**
532+
don:core:dvrv-us-1:devo/11FVC3ScK:stage/3]
533+
compl[**Completed**
534+
don:core:dvrv-us-1:devo/11FVC3ScK:stage/4]
535+
backl --> dev --> rca --> compl
536+
```
495537

496538
```curl {11}
497539
curl --location 'https://api.devrev.ai/stage-diagrams.create' \

fern/docs/pages/webhooks.mdx

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,24 @@ The types of events that can be received through webhooks are object mutation ev
1414
Events are delivered concurrently in a semi-ordered (but not guaranteed) manner,
1515
where object timestamps and versions enable you to determine the order of events for a particular object.
1616

17-
![diagram_4](../img/diagram_4.png)
17+
```mermaid
18+
sequenceDiagram
19+
%%{init: {
20+
'theme': 'base',
21+
'themeVariables': {
22+
'fontFamily': 'Segoe UI',
23+
'signalColor': '#7d7f7c',
24+
'signalTextColor': '#7d7f7c'
25+
}}}%%
26+
Note over Customer endpoint,DevRev: 1. Register webhook
27+
Customer endpoint ->> DevRev: Webhook create request
28+
DevRev -->> Customer endpoint: Webhook create response
29+
Note over Customer endpoint,DevRev: 2. Verify webhook registration
30+
DevRev ->> Customer endpoint: Verify request
31+
Customer endpoint -->> DevRev: Echo challenge
32+
Note over Customer endpoint,DevRev: 3. Receive webhook event
33+
DevRev ->> Customer endpoint: Event POST
34+
```
1835

1936
## Webhook event handling
2037

fern/versions/beta.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ navigation:
1111
typescript: "@devrev/api"
1212
- section: Guides
1313
contents:
14-
- page: Object Customization
14+
- page: Object customization
1515
path: ../docs/pages/customization.mdx
16-
- page: Custom Objects
16+
- page: Custom objects
1717
path: ../docs/pages/custom-objects.mdx
18-
- page: Create accounts and contacts in DevRev
18+
- page: Account creation
1919
path: ../docs/pages/create-accounts.mdx

fern/versions/public.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ navigation:
5959
- section: Guides
6060
slug: guides
6161
contents:
62-
- page: Getting started with webhooks
62+
- page: Webhooks
6363
slug: webhooks
6464
path: ../docs/pages/webhooks.mdx
6565
- page: Restricted messages on a timeline

0 commit comments

Comments
 (0)