Building a Micetro API Collection

Not sure how to begin automating your DDI environment? Get started with our Basic Micetro API collection.

May 19th, 2022

Using saved collections to create a library of API calls can has a few benefits. We've started creating our own collection for you to use when you're ready to get started automating your DDI environment.

If you'd prefer to watch the on-demand video just click play below.

What are Postman Collections?

Collections are essentially just a group of API calls that you've deemed have something in common. Maybe they're part of a larger lifecycle workflow including DNS record creation and IP address assignment, or maybe they all go to the same API. This would make a lot of sense because one of the benefits of using a collection is that you can setup authorization just one time and tell all of the calls to use that same method.

To create a new collection you only need to go into your preferred Postman Workspace, click the New button and select Collection. Give it a name and you're done. Now you can add and save API calls as you like.

Micetro API Postman Collection

Inheriting Authorization from Parent

Once you have a collection you can highlight the top level (the name of the collection) and then click on the Authorization tab. For Micetro you'll select Basic Auth (or NTLM auth depending on if you're using SSO) and enter the proper user name and password.

Basic Auth for Collection

Now for each API call, by default it will select "Inherit auth from Parent" which means it will use the authorization method as we just specified above for the collection. This means we don't have to go through and specify authorization for each individual call, which can make things a lot easier when we start getting dozens of calls perhaps. Though it is possible to change the auth

Authorization Methods - Inherit auth from parent is default

Sharing Collections

The other benefit of using collections in Postman is that you can share them by using import/export features. If you just click on the meatball menu next to your collection and choose export, you can export this collection to your local machine to share with your colleagues or the broader community.

We can import collections by clicking on the Import button at the top of the app. Here you can either import something from your local machine or there are other options there as well, such as importing the raw content.

Importing the Micetro API Collection from Men&Mice

As part of our initiative to make this kind of information more freely available to our customers we've created a Github/Postman integration to make our Micetro collections publicly available to you all.

If you go to the Men&Mice Github page you'll see all of our publicly available repos. We now have the Postman-Collections repo available for everyone to use. There are a couple ways you can choose to use this repo. First you can Fork the repo to copy it over to your own account. This will let you make modifications to it and even create pull requests if you'd like us to add or change something to our repo. For more information on how to do this, check out our blog about GitHub for Beginners or watch the video below.

The other way you can use this content is to go inside one of the files, by clicking on the Postman-Collections file and then clicking on Micetro-Basic-Collection.json for example. on the upper right of the file itself is a "copy raw contents" button you can click  on. Then go back to Postman and click on the Import button. Click on the Raw text option, and then just paste the raw contents there and click continue.

Importing from GitHub Raw Text

Next Steps

I highly recommend just jumping in and getting started with this basic collection, which contains GET, POST, PUT, and DELETE calls. Between the API documentation, videos from the Men&Mice Automation Playlist, and this Postman collection you should have enough to get started building your own APIs.

Please reach out with any questions, and if you have any suggestions for workflow demos, we'll gladly take those as well. We'd also love to spotlight any customers getting started with their automation journey or who are well into it! Please reach out if you'd like to write a guest blog or appear on a live demo. We'd love to share your genius with the rest of the DDI community.