All Projects → itglue → powershellwrapper

itglue / powershellwrapper

Licence: Apache-2.0 license
This PowerShell module acts as a wrapper for the IT Glue API.

Programming Languages

powershell
5483 projects

Projects that are alternatives of or similar to powershellwrapper

Discogs
A Ruby wrapper of the Discogs.com API
Stars: ✭ 195 (+103.13%)
Mutual labels:  api-wrapper
Play Store Api
Google Play Store protobuf API wrapper in java
Stars: ✭ 249 (+159.38%)
Mutual labels:  api-wrapper
knowledgeworks api
The API utils for querying CN-DBpedia & CN-Probase, the biggest Chinese knowledge bases
Stars: ✭ 24 (-75%)
Mutual labels:  api-wrapper
Python Onedrive
Obsolete python/cli module for MS SkyDrive/OneDrive's old API, do not use for new projects
Stars: ✭ 202 (+110.42%)
Mutual labels:  api-wrapper
Python Scrapyd Api
A Python wrapper for working with Scrapyd's API.
Stars: ✭ 235 (+144.79%)
Mutual labels:  api-wrapper
conekta-elixir
Elixir library for Conekta api calls
Stars: ✭ 15 (-84.37%)
Mutual labels:  api-wrapper
Virustotal Api
Virus Total Public/Private/Intel API
Stars: ✭ 189 (+96.88%)
Mutual labels:  api-wrapper
wikipedia-reference-scraper
Wikipedia API wrapper for references
Stars: ✭ 34 (-64.58%)
Mutual labels:  api-wrapper
Betfair
betfairlightweight - python wrapper for Betfair API-NG (with streaming)
Stars: ✭ 246 (+156.25%)
Mutual labels:  api-wrapper
hata
Async Discord API wrapper.
Stars: ✭ 156 (+62.5%)
Mutual labels:  api-wrapper
Taxize
A taxonomic toolbelt for R
Stars: ✭ 209 (+117.71%)
Mutual labels:  api-wrapper
Php Ovh
Lightweight PHP wrapper for OVH APIs. That's the easiest way to use OVH.com APIs in your PHP applications.
Stars: ✭ 230 (+139.58%)
Mutual labels:  api-wrapper
cvpysdk
Developer SDK - Python
Stars: ✭ 50 (-47.92%)
Mutual labels:  api-wrapper
Binance
A .NET Standard Binance API library.
Stars: ✭ 199 (+107.29%)
Mutual labels:  api-wrapper
cpAPI
A Flask API that gives updates about the upcoming contests on various Coding Platforms.
Stars: ✭ 13 (-86.46%)
Mutual labels:  api-wrapper
Github4s
A GitHub API wrapper written in Scala
Stars: ✭ 194 (+102.08%)
Mutual labels:  api-wrapper
Notion Api
Unofficial Notion.so API
Stars: ✭ 250 (+160.42%)
Mutual labels:  api-wrapper
ruby-ambassador
Ambassador API v2 wrapper for Ruby
Stars: ✭ 20 (-79.17%)
Mutual labels:  api-wrapper
messages
A python package designed to make sending messages easy and efficient!
Stars: ✭ 38 (-60.42%)
Mutual labels:  api-wrapper
java-binance-api
Java Binance API Client
Stars: ✭ 72 (-25%)
Mutual labels:  api-wrapper

IT-Glue-API-PowerShell-Wrapper

This PowerShell module acts as a wrapper for the IT Glue API.


Introduction

IT Glue's API offers the ability to read, create, and update much of the data within IT Glue's documentation platform. That includes organizations, contacts, configuration items, and more. Full documentation for IT Glue's RESTful API can be found here.

This module serves to abstract away the details of interacting with IT Glue's API endpoints in such a way that is consistent with PowerShell nomenclature. This gives system administrators and PowerShell developers a convenient and familiar way of using IT Glue's API to create documentation scripts, automation, and integrations.

Function Naming

IT Glue features a REST API that makes use of common HTTP(s) GET, POST, PATCH, and DELETE actions. In order to maintain PowerShell best practices, only approved verbs are used. As such, the following mapping should be utilized:

  • GET -> Get-
  • POST -> New-
  • PATCH -> Set-
  • DELETE -> Remove-

Additionally, PowerShell's verb-noun nomenclature is respected. Each noun is prefixed with ITGlue in an attempt to prevent any naming problems.

For example, one might access the /users/ API endpoint by running the following PowerShell command with the appropriate parameters:

Get-ITGlueUsers

Installation

This module can be installed directly from the PowerShell Gallery with the following command:

Install-Module -Name ITGlueAPI

If running an older version of PowerShell, or if PowerShellGet is unavailable, one can manually download the Master branch and place the "ITGlueAPI" folder into the (default) C:\Program Files\WindowsPowerShell\Modules folder.

After installation (by either methods), load the module into your workspace:

Import-Module ITGlueAPI

Initial Setup

The first time you run this module, you will need to configure the base URI and API key that are used to talk with IT Glue. Doing so is as follows:

  1. Run Add-ITGlueBaseURI. By default, IT Glue's api.itglue.com uri is entered. If you have your own API gateway or proxy, you may put in your own custom uri by specifiying the -base_uri parameter, as follows: Add-ITGlueBaseURI -base_uri http://myapi.gateway.example.com.

  2. Run Add-ITGlueAPIKey. It will prompt you to enter your API key (please refer to IT Glue's documentation here for generating an API key).

  3. [optional] If you would like the IT Glue module to remember your base uri and API key, you can run Export-ITGlueModuleSettings. This will create a config file at %UserProfile%\ITGlueAPI that securely holds this information. Next time you run Import-Module, this configuration will automatically be loaded.

⚠️ Exporting module settings encrypts your API key in a format that can only be unencrypted with your Windows account. It makes use of PowerShell's System.Security.SecureString type, which uses reversible encrypted tied to your user principal. This means that you cannot copy your configuration file to another computer or user account and expect it to work.

⚠️ Exporting and importing module settings requires use of the ConvertTo-SecureString cmdlet, which is currently unavailable in Linux and Mac PowerShell core ports. Until PS Core 6.0.0 is available, this functionality only works on Windows.

Usage

Calling an API resource is as simple as running Get-ITGlue<resourcename>. The following is a table of supported functions and their corresponding API resources:

API Resource Create Read Update Delete
Attachments New-ITGlueAttachments - Set-ITGlueAttachments Remove-ITGlueAttachments
Configuration Interfaces New-ITGlueConfigurationInterfaces Get-ITGlueConfigurationInterfaces Set-ITGlueConfigurationInterfaces -
Configuration Statuses New-ITGlueConfigurationStatuses Get-ITGlueConfigurationStatuses Set-ITGlueConfigurationStatuses -
Configuration Types New-ITGlueConfigurationTypes Get-ITGlueConfigurationTypes Set-ITGlueConfigurationTypes -
Configurations New-ITGlueConfigurations Get-ITGlueConfigurations Set-ITGlueConfigurations Remove-ITGlueConfigurations
Contact Types New-ITGlueContactTypes Get-ITGlueContactTypes Set-ITGlueContactTypes -
Contacts New-ITGlueContacts Get-ITGlueContacts Set-ITGlueContacts Remove-ITGlueContacts
Countries - Get-ITGlueCountries - -
Documents - - Set-ITGlueDocuments -
Domains - Get-ITGlueDomains - -
Expirations - Get-ITGlueExpirations - -
Flexible Asset Fields New-ITGlueFlexibleAssetFields Get-ITGlueFlexibleAssetFields Set-ITGlueFlexibleAssetFields Remove-ITGlueFlexibleAssetFields
Flexible Asset Types New-ITGlueFlexibleAssetTypes Get-ITGlueFlexibleAssetTypes Set-ITGlueFlexibleAssetTypes -
Flexible Assets New-ITGlueFlexibleAssets Get-ITGlueFlexibleAssets Set-ITGlueFlexibleAssets Remove-ITGlueFlexibleAssets
Groups - Get-ITGlueGroups - -
Locations New-ITGlueLocations Get-ITGlueLocations Set-ITGlueLocations Remove-ITGlueLocations
Manufacturers New-ITGlueManufacturers Get-ITGlueManufacturers Set-ITGlueManufacturers -
Models New-ITGlueModels Get-ITGlueModels Set-ITGlueModels -
Operating Systems - Get-ITGlueOperatingSystems - -
Organization Statuses New-ITGlueOrganizationStatuses Get-ITGlueOrganizationStatuses Set-ITGlueOrganizationStatuses -
Organization Types New-ITGlueOrganizationTypes Get-ITGlueOrganizationTypes Set-ITGlueOrganizationTypes -
Organizations New-ITGlueOrganizations Get-ITGlueOrganizations Set-ITGlueOrganizations Remove-ITGlueOrganizations
Password Categories New-ITGluePasswordCategories Get-ITGluePasswordCategories Set-ITGluePasswordCategories -
Passwords New-ITGluePasswords Get-ITGluePasswords Set-ITGluePasswords Remove-ITGluePasswords
Platforms - Get-ITGluePlatforms - -
Regions - Get-ITGlueRegions - -
Related Items New-ITGlueRelatedItems - Set-ITGlueRelatedItems Remove-ITGlueRelatedItems
User Metrics - Get-ITGlueUserMetrics - -
Users - Get-ITGlueUsers Set-ITGlueUsers -

Note, table entries with - indicate that the functionality is not supported by the IT Glue API.

Each Get- function will respond with the raw data that IT Glue's API provides. Usually, this data has at least three sub-sections:

  • data - The actual information requested (this is what most people care about)
  • links - Links to specific aspects of the data
  • meta - Information about the number of pages of results are available and other metadata.

Each resource allows filters and parameters to be used to specify the desired output from IT Glue's API. Check out the wiki article on Using Filters and Parameters.

A full list of functions can be retrieved by running Get-Command -Module ITGlueAPI. Help info and a list of parameters can be found by running Get-Help <command name>, such as:

Get-Help Get-ITGlueUsers

Wiki 📖

For more information about using this module, as well as examples and advanced functionality, check out our wiki!

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].