After watching the last movie of Marvel, Black Panther, I was starting to search about the world of comics and wrote a small PowerShell module to interact with the Marvel Comics REST API.
Marvel had publish a REST API which allows you to gather data regarding the entire Marvel Comics Universe and to create amazing websites and apps with that free data. For example, you can access to the characters info, comics, comics stories and much more. And you might be wondering what this has to do with PowerShell? Well, I love reading and searching about everything. I knew I had to find a way to add this into the console. So, I created a module to access to all the information from PowerShell console. 😎
Installing the module
The module can be installed from the PowerShell Gallery using the following complex command:
How does it work?
There are a couple of things you will need to setup before you can use the module:
First, setup a Marvel API key (create an account): link. After completing the registration process you’ll have this data:
With the keys, you can start to consume the API using the cmdlet Invoke-RestMethod. I wrote the following function to start accessing information:
How can you search any character? We’ll use the parameter nameStartsWith with the URL and the apikey like this:
And manipulate the data:
The result:
What does the module contain?
The module has the following commands:
Example
Contributing
The module is available on github here, feel free to contribute via issues or pull requests.
As artificial intelligence (AI) continues to transform the way we work and live, more and more businesses are turning to powerful AI tools to improve their o...
Azure Chaos Studio is a manage service offered by Microsoft as part of its Azure cloud platform that enables users to test the resilience and reliability of ...
Dado el uso de Terraform para la definición de recursos, una necesidad que ha surgido en las tareas de gestión de los mismos, es la posibilidad de importar r...
Comments