Commit 5319371d authored by Alper Akgun's avatar Alper Akgun Committed by Kati Paizee

Docs for trial lead flow

parent a7cc1737
...@@ -92,7 +92,48 @@ The flow of a PQL lead is as follows: ...@@ -92,7 +92,48 @@ The flow of a PQL lead is as follows:
1. Marketo does scoring and sends the form to Salesforce. 1. Marketo does scoring and sends the form to Salesforce.
1. Our Sales team uses Salesforce to connect to the leads. 1. Our Sales team uses Salesforce to connect to the leads.
### Lead flow on GitLab.com ### Trial lead flow
#### Trial lead flow on GitLab.com
```mermaid
sequenceDiagram
Trial Frontend Forms ->>TrialsController#create_lead: GitLab.com frontend sends [lead] to backend
TrialsController#create_lead->>CreateLeadService: [lead]
TrialsController#create_lead->>ApplyTrialService: [lead] Apply the trial
CreateLeadService->>SubscriptionPortalClient#generate_trial(sync_to_gl=false): [lead] Creates customer account on CustomersDot
ApplyTrialService->>SubscriptionPortalClient#generate_trial(sync_to_gl=true): [lead] Asks CustomersDot to apply the trial on namespace
SubscriptionPortalClient#generate_trial(sync_to_gl=false)->>CustomersDot|TrialsController#create(sync_to_gl=false): GitLab.com sends [lead] to CustomersDot
SubscriptionPortalClient#generate_trial(sync_to_gl=true)->>CustomersDot|TrialsController#create(sync_to_gl=true): GitLab.com asks CustomersDot to apply the trial
```
#### Trial lead flow on CustomersDot (sync_to_gl)
```mermaid
sequenceDiagram
CustomersDot|TrialsController#create->>HostedPlans|CreateTrialService#execute: Save [lead] to leads table for monitoring purposes
HostedPlans|CreateTrialService#execute->>BaseTrialService#create_account: Creates a customer record in customers table
HostedPlans|CreateTrialService#create_platypus_lead->>PlatypusLogLeadService: Creates a platypus lead
HostedPlans|CreateTrialService#create_platypus_lead->>Platypus|CreateLeadWorker: Async worker to submit [lead] to Platypus
Platypus|CreateLeadWorker->>Platypus|CreateLeadService: [lead]
Platypus|CreateLeadService->>PlatypusApp#post: [lead]
PlatypusApp#post->>Platypus: [lead] is sent to Platypus
```
#### Applying the trial to a namespace on CustomersDot
```mermaid
sequenceDiagram
HostedPlans|CreateTrialService->load_namespace#Gitlab api/namespaces: Load namespace details
HostedPlans|CreateTrialService->create_order#: Creates an order in orders table
HostedPlans|CreateTrialService->create_trial_history#: Creates a record in trial_histories table
```
### Hand raise lead flow
#### Hand raise flow on GitLab.com
```mermaid ```mermaid
sequenceDiagram sequenceDiagram
...@@ -100,9 +141,9 @@ sequenceDiagram ...@@ -100,9 +141,9 @@ sequenceDiagram
TrialsController#create_hand_raise_lead->>CreateHandRaiseLeadService: [lead] TrialsController#create_hand_raise_lead->>CreateHandRaiseLeadService: [lead]
CreateHandRaiseLeadService->>SubscriptionPortalClient: [lead] CreateHandRaiseLeadService->>SubscriptionPortalClient: [lead]
SubscriptionPortalClient->>CustomersDot|TrialsController#create_hand_raise_lead: GitLab.com sends [lead] to CustomersDot SubscriptionPortalClient->>CustomersDot|TrialsController#create_hand_raise_lead: GitLab.com sends [lead] to CustomersDot
``` ```
### Lead flow on CustomersDot and later #### Hand raise flow on CustomersDot
```mermaid ```mermaid
sequenceDiagram sequenceDiagram
...@@ -111,9 +152,9 @@ sequenceDiagram ...@@ -111,9 +152,9 @@ sequenceDiagram
Platypus|CreateLeadWorker->>Platypus|CreateLeadService: [lead] Platypus|CreateLeadWorker->>Platypus|CreateLeadService: [lead]
Platypus|CreateLeadService->>PlatypusApp#post: [lead] Platypus|CreateLeadService->>PlatypusApp#post: [lead]
PlatypusApp#post->>Platypus: [lead] is sent to Platypus PlatypusApp#post->>Platypus: [lead] is sent to Platypus
``` ```
### Lead flow after Platypus ### PQL flow after Platypus for all lead types
```mermaid ```mermaid
sequenceDiagram sequenceDiagram
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment