cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Learn all about PTC Community Badges. Engage with PTC and see how many you can earn! X

How to request a mashup url?

CHASEONHO
18-Opal

How to request a mashup url?

Hello

 

How do I request a url for a mashup?
I showed mashups using an iframe in html.


This seems unstable.

Can I request url via parameters?


How do I do this?

thank

1 ACCEPTED SOLUTION
6 REPLIES 6

The URL for any mashup should be easy to know if you already know the mashup name.  It just uses this pattern:

 

/Thingworx/Runtime/index.html#mashup=<mashup_name>

 

Fior me, this is a mashup on a server:

http://localhost:8080/Thingworx/Runtime/index.html#mashup=3DPrinter

 

If you want to get a list of all Mashup names, you can do that by REST services (you must authenticate) by simply doing a GET on:

http://localhost:8080/Thingworx/Mashups

supandey
19-Tanzanite
(To:CHASEONHO)

Hi @CHASEONHO could you please elaborate a bit on what you meant by requesting the URL. And what's unstable about using that in the iframe.

Hi,  supandey

The way I need the url I mentioned is to hide the parameter and request the url to display the mashup in the iframe.
Typically, to display a mashup without a login, you would use the following format:
<ServerName>: <ServerPort> / Thingworx / mashups / <mashupName> & <appkey>
I am wondering how to access the mashup by passing it as a parameter rather than displaying it.
If you have a way to pass Thingworx Session, AppKey without displaying it in url, please let me know.

Thank you.

 

PaiChung
22-Sapphire I
(To:CHASEONHO)

If you need to pass in parameters it gets a little more interesting because you would probably need to accomplish a few things

1. establish a session

2. have the right url

3. pass in parameters

to establish the session you would have to set x-thingworx-session to true

you also need to probably pass in an appkey

and then the parameters.

The link provided can be used to also pass in parameters with &parameterName=parameterValue BUT you can't establish session.

When establishing session you can't pass in the parameter names.

I don't remember if there is a solution for that or not.

Best way is to first establish session and then call a mashup with the parameters.

@PaiChung

Can I request a mashup without displaying the ack in url?
Attempt to put the requested url into an iframe.
Is this possible?

thank you

Top Tags