description |
---|
Step-by-step guide on sending test events to verify your RudderStack installation. |
{% hint style="info" %} This guide assumes you have already installed and set up RudderStack. {% endhint %}
There are two ways in which you can send test events to verify your RudderStack installation:
- Using the bundled shell script
- Using RudderStack's HTTP API
In our GitHub repository, we have bundled a shell script that generates test events. Follow the steps below:
Before sending test events to verify your RudderStack installation, clone the RudderStack GitHub repository by running the following command:
git clone https://github.com/rudderlabs/rudder-server.git
Then, follow the sections below to send events to test your RudderStack installation.
Option 1: If you have signed up for RudderStack Cloud, follow these steps to get your source write key:
- Set up a source and a destination in RudderStack by following this guide.
- You can find the write key in the dashboard, as shown:
{% hint style="warning" %} The write key is different from your workspace token. The write key is associated with the source, while the workspace token is associated with your RudderStack workspace. {% endhint %}
Option 2: If you are self-hosting RudderStack and have set up the control plane using the Control Plane Lite utility, you can find the source write key by following these steps:
- Set up a source and a destination by following this guide.
- You can find the write key associated with the source in the dashboard as shown:
- In your terminal, navigate to the folder where RudderStack is installed.
- Then, run the following command after replacing
<YOUR_WRITE_KEY>
with the source write key obtained in the previous section:
./scripts/generate-event <YOUR_WRITE_KEY> https://hosted.rudderlabs.com/v1/batch
- You can then check your destination to verify that events are delivered. You can also view the live events via RudderStack's Live Events ****tab.
- In your terminal, navigate to the folder where RudderStack is installed.
- Then, run the following command after replacing
<YOUR_WRITE_KEY>
with the source write key obtained in the previous section, and<DATA_PLANE_URL>
with your Data Plane URL.
./scripts/generate-event <YOUR_WRITE_KEY> <DATA_PLANE_URL>/v1/batch
An example is as shown:
- You can then check your destination to verify that the events are delivered.
{% hint style="info" %} Note that unlike RudderStack Cloud, the Control Plane set up using Control Plane Lite ****utility does not let you view live events. {% endhint %}
If you supply an invalid source write key or Data Plane URL, you will get the following error:
- Import this Postman collection. ****
- Edit the variables
source_write_key
anddata_plane_url
in this collection with your source write key and your RudderStack Data Plane URL. - RudderStack uses Basic Authentication for authenticating all the HTTP requests. The HTTP Basic Authentication requires a user name and password where:
- The user name is the
source_write_key
- The password is an empty string (
""
)
- The user name is the
- Now you can test all the supported requests.
If you have signed up for RudderStack Cloud, follow these steps to get your source write key:
- Set up a source in RudderStack by following this guide.
- You can find the write key in the dashboard, as shown:
{% hint style="warning" %} The write key is different from your workspace token. The write key is associated with the source, while the workspace token is associated with your RudderStack workspace. {% endhint %}
If you are self-hosting RudderStack and have set up the control plane using Control Plane Lite, you can find the source write key by following these steps:
- Set up a source by following this guide.
- You can find the write key associated with the source in the dashboard as shown:
{% hint style="info" %} Follow this section for details on how to get your Data Plane URL. {% endhint %}
{% hint style="success" %} Refer to the HTTP API guide for more information on the supported calls. {% endhint %}
If you come across any issues while sending test events to verify your RudderStack installation, you can contact us or start a conversation on our Slack channel.