Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Passageway – Expose Localhost to Public

DZone's Guide to

Passageway – Expose Localhost to Public

If you're working on REST APIs, there are often times when you'll need to expose the API to the public, or social source integration. This requires callback URL configuration. Here's a quick Runscope tutorial on exposing a localhost to public.

Free Resource

The Integration Zone is brought to you in partnership with Cloud Elements. What's below the surface of an API integration? Download The Definitive Guide to API Integrations to start building an API strategy.

 When we are working on REST APIs there are situations where you may require exposing the APIs to public or if you are working with any social source integration where we need to configure callback URLs, we require to host our APIs onto the public IP address. Getting the public IP from the network department is a tedious process (Requires tickets, approvals and followups). Here is a tool called “Passageway” (from Runscope) which will  allow us to expose the localhost to public. Follow the below steps to setup Passageway.

Step1: Create an account with https://www.runscope.com/signup

Step2: Login to “Runscope” and create a bucket.

Create Bucket







Step 3: Download the “Passageway” from here. The “Passageway” agents are available for different operating systems.

Step 4: Open the command prompt and run the “Passageway” agent as shown below.

Run Passageway



Step 5: Then, it will prompt to select the “bucket” which we created in Step2 and the port number for which the “Passageway” will route the requests on to our localhost. After providing the details, “Passageway” will provide us the forward URL which will be accessible from the public.

Passageway Forward URL

         



We are done. Now, we can expose the APIs running on the localhost to public. Use the base URL provided by “Passageway” and append your URI to that. When we make a request to “Passageway,” the request will be forwarded to localhost on the registered port(Port is provided in Step5) through “Passageway.”

Your API is not enough. Learn why (and how) leading SaaS providers are turning their products into platforms with API integration in the ebook, Build Platforms, Not Products from Cloud Elements.

Topics:
public ,integration ,localhost ,passageway

Published at DZone with permission of Siva Prasad Rao Janapati, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}