Event Tags

Sometimes you will want to group APIs together. This is especially true if a few different endpoints compose an API product. In Moesif, you can group events together by using Tags.

Creating an Event Tag

The first step in creating an event tag is to navigate to the Live Event Log screen. This can be done by going to the + New button and selecting Live Event Log.

Once on the Live Event Log screen, create a filter you’d like to apply to the tag. In the example below, we will add two endpoints to the filter. Once the filter is determined, you can create the tag by clicking on the Create Tag button.

Adding a filter to Moesif and highlighting the Create Tag button

A modal will then appear which shows the filter for the tag. Add a name for the tag and then click the Create “X” prompt that displays in the dropdown for your new tag.

Create Tag dropdown

Lastly, click the Create Tag button in the bottom right of the modal to generate the tag.

Completed Create Tag Modal

Updating a tag will also update old events. However, this may take a few minutes. You can view the processing status of tags from the Tag manager.

Accessing Existing Tags Through The Tags Manager Screen

To edit existing tags, you can access them through the Tags Manager. This can be accessed through the Settings menu at the bottom of the screen in Moesif.

Tag Manager item in Settings menu

Once clicked, you’ll be able to see previously created tags, edit them, and delete them.

Tags Manager main screen

Creating Event Tags Using an OpenAPI Spec

From the Tags Manager screen you can automatically create tags based on an imported OpenAPI spec. To do this, simply upload or drag and drop your OpenAPI Spec into the app and tags will be automatically generated.

Adding OpenAPI Spec to Create Tags

Editing an Event Tag

To edit a tag, navigate to the Tags Manager screen and click the ellipsis button at the end of the entry and click Edit.

Edit Tag button

A modal will then pop up and allow you to edit the filter for the tag. Once completed, click the Save button.

Edit Tag modal

Deleting an Event Tag

To delete a tag that you no longer want to use, navigate to the Tags Manager screen and click on the ellipsis button for the entry and click Delete.

Delete Tag button

A modal will then appear to confirm the deletion. Click Yes to delete the tag.

Delete Tag modal

Using an Event Tag

Using an event tag can be used just as any other attribute. A good example of this would be using the tag in a live event log query. Instead of having to specify the endpoints, you can then just specify to include events that match the tags. Below is a quick demonstration of what that filter would look like and the output.

Using an event tag in Moesif

You’ll also notice that entries also show the tags that they are part of. Each of the entries in the examples shows the Categories API tag.

Similarly, you can group by tag names just like any other attribute. Below we can see the traffic volume for each of our APIs. This can be helpful to organize your endpoints into API products when creating billing meters.