Dashboards & Visualizations

How do I search for events under a Splunk Token?

tycarterbk1
New Member

I have the following token value "7FB3A2D9......"
I want to view events submitted under this token.
• Number of events
• Details of event

Tags (2)
0 Karma

lucasfbeinjamin
Path Finder

Hey buddy @tycarterbk1
I do not know if it's exactly what you wanted but I tried to answer you through an example code, hope you can approve and learn something from it.

<form>
<row>
    <panel>
      <input type="dropdown" token="YOUR_TOKEN" searchWhenChanged="true">
        <fieldForLabel>your_field</fieldForLabel>
        <fieldForValue>your_field</fieldForValue>
        <search>
          <query>index=YOUR_INDEX sourcetype=YOUR_SOURCETYPE
| dedup field1
| table field1</query>  <!--(I'm doing that to populate the dropdown)-->
          <earliest>-24h@h</earliest>
          <latest>now</latest>
        </search>
        <default>7FB3A2D9</default> <!-- Here i set a default value to the dropdown-->
      </input>

  <!-- SEARCH 1 -->
  <row>
    <panel>
      <chart>
        <search>
          <query>index=YOUR_INDEX sourcetype=YOUR_SOURCETYPE $YOUR_TOKEN$ 
| stats count() by id <!--(Here you can count your events by anything you need "id, code, etc...")-->
</query>
        </search>
      </chart>
    </panel>
  </row>

  <!-- SEARCH 2 -->
  <row>
    <panel>
      <chart>
        <search>
          <query>index=YOUR_INDEX sourcetype=YOUR_SOURCETYPE $YOUR_TOKEN$ 
| table Field1, Field2, Field3 .... <!--(Here you put your fields that you need)-->
          </query>
        </search>
        </chart>
     </panel>
   </row>
</form>
0 Karma

lucasfbeinjamin
Path Finder

Hey @tycarterbk1
Please i need more information about your query to be able to respond in the best possible way.

0 Karma

tycarterbk1
New Member

Hi @lucasfbeinjamin
I have a following token value "7FB3A2D9......"
The user wants to see • Number of events and • Details of event associated with this token.
Does this clear things up?
I do not have a query thats what I'm trying to figure out now

0 Karma

mstjohn_splunk
Splunk Employee
Splunk Employee

hi @tycarterbk1

Thanks for posting. Could you give us some more context for your query? You have a much better chance of getting your question answered if you provide more information about your issue. Plus, it will help guide future community users who are facing a similar problem.

0 Karma

tycarterbk1
New Member

Hi @mstjohn_splunk
I have a following token value "7FB3A2D9......"
The user wants to see • Number of events and • Details of event associated with this token.

Does this clear things up?

0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...