Open custom app with a payload using a URL - javascript

If this heading is not clear, I’ll clarify. Before that I have to mention that this question is not a homework but I’m curious to make this kind of an application. But couldn’t verify whether following problem can be solved. So please help me to verify whether this is possible before I start my project.
Let’s say I have a custom developed app which select best image of the week of a weekly competition. Also users can vote and share voted images on facebook. However let’s say there are two persons called X and Y. X has already installed the app and he can vote and share images. And when it comes to Y, it has two scenarios.
1) Y also have the app installed. So when she click the URL X shared, this URL should open the installed app and should view the relevant image with details such as votes and shares.
2) Y still have not downloaded the app. So URL should bring her to App Store or Play store based on mobile platform.
Second scenario has a solution. But when it comes to first one, how can I push the payload ( details of images and content) with the link to show required details whenever app completes loading? I went through lots of articles but still couldn’t find a solution. Can someone help me?

I found a solution for my need.
It's better to call an API to get data I need using an image ID which is unique to each images. So each link of an image contains the app URL with image ID. So when app opens by an external link,Which can be captured by using Deep Link (React native Linking Library) and API call will make to the backend and get all relevant data.
This tutorial shows all relevant steps to do that.

Related

How can i code Zapier to follow a link that was provided in an email?

I am using Mailparser to scrape a booking email, then use Zapier to create a booking in our system.
In the email is a link to confirm the booking so am wanting to use the code action to click on the link or follow the link.
Nothing needs to be seen, just follow the link & allow the page to load. This confirms the reservation
I have attempted using python & JS to no avail.
Can you point me in the right direction?
Thanks for reading!
David here, from the Zapier Platform team.
When you click on a link and it opens in your browser, all that really is is a GET request. If the site you're trying to load is simple, then this can be accomplished with a Webhook by Zapier step that make the request to the provided URL.
The big issue that'll pop up is if the site is more complex. A browser loads and execute all the javascript on the page, which our GET request won't do. If the site uses javascript to confirm the reservation (not just the page loading itself), then this isn't going to work. If that's the case, it's a lot more involved. You'd probably need to make a CLI app and use a tool like PhantomJS that can load pages and everything in them. Note that I haven't tested that on the CLI and there's a chance it's incompatible with the way we run apps, so do a proof of concept before you really dive in.
Hope this helps. ​Let me know if you've got any other questions!

Google Analytics: Do I need URL address?

I am a complete Google Analytics beginner and would appreciate a help with a basic question.
I am developing HTML, CSS and JavaScript based applications which are further uploaded into an iOS application to present your applications in a fancy way. Therefore my application is a hybrid application (half JS web site, half mobile app).
I would love to see users' activity in my app when they are browsing through it and I thought GA might work well with it - but the problem is, that the outer app doesn't provide me with any URL of my inner JS app (the inner web site's URL is file:///).
At this page (link), I found that URL is not really important, that it is the tracking code which is important. So I used a dummy URL, added the GA snippet into my application and uploaded it in iPresent. I can't see no live activity though... :/ It also says the measuring is not installed (not used at a home page).
So I am wondering - is the URL really important?
Any ideas?
Thanks!
URL (or page path) is only important if you want to report on data based on which URLs your visitors went to.
If you app doesn't use URLs at all, perhaps it fits better with the "app" model where you are sending screen name data instead of page data. You can read more about the differences between web and app views here:
https://support.google.com/analytics/answer/2649553
I found out that URL is not needed. This type of problem can be solved by using GA Measurement Tool
https://developers.google.com/analytics/devguides/collection/protocol/v1/
Validate your hit here:
https://ga-dev-tools.appspot.com/hit-builder/

Issue with editing of Path authentication page

So I have next issue. My app export some images to Path(some social network, as I think), and I use Amazon appstore for sharing my app. But the authentication page of Path, which I fetch in webview has a link to Apple Store and Google Play Market, that's very bad, because of amazon policy disallows such links and I can't publish my app. Here is example of such authentication page - https://partner.path.com/oauth2/authenticate?response_type=code&client_id=1b81bf92642176a90222d90c5ca5c2c6937f4dd7.
First of all, I tried to find some way to edit downloaded page - use javascript to get code of page, delete a link and fetch it back to webview. But after such manipulations webview stop to respond on clicks and I can't log in. I done smth like in this post - Is it possible to get the HTML code from WebView.
So I ask your help guys in next issue - I need working variant of authentication page of Path without any links to any markets.
everybody! It's not possible to edit the page in way it will working correctly after it. So I was forced to delete this function from my app.
Also I have written an email to Path team - they just answered that they don't going to change their authentication page in near future.

Trouble linking the consumer key to my Soundcloud using application.js

I am trying to recreate the link in my own personal site. I have included all files that are necessary, and linked to them accordingly. I followed the instructions from this page http://soundcloud-sm2.heroku.com/docs/application.html and at the point where it says Pass a consumer key, which can be created here, and your playlist url. I created an app and copied the client_id which I'm presuming is the "consumer key" and put in the link to a set i created. For some reason it doesn't seem to be working. Am I supposed to fill in all the fields when creating the app or are they not necessary? I'm building in my localhost, am I supposed to be live for it to take affect?
Here is what I am trying to achieve working, I just don't know where I'm going wrong. http://soundcloud-sm2.heroku.com

Facebook like error - disabled/not visible

We've got a number of content managed sites that use the same functionality. We added a site recently, and the Facebook like button is failing with an error on-click (following Facebook login):
This page is either disabled or not visible to the current user.
This only happens when the Facebook user isn't an administrator of the page, or of an application we've created for the page.
The site where this is failing is here: http://beachhousemilfordonsea.co.uk/
An example of a site that works (same code): http://monmouthash.co.uk/
The Facebook like code:
<fb:like href="http://beachhousemilfordonsea.co.uk/" width="380"></fb:like>
Actions already taken
I've checked with the FB Linter and there are a couple of Opengraph warnings that do need to be fixed (add a description, increase the image size) - but these are the same for all sites so should be affecting this (it's on the dev plan to get these rectified in the next release).
I've taken a look at the Facebook App we've got running on the problem page, and checked it against other working applications and the settings are the same as far as I can see, except there are missing options with this new application:
Encrypted access token (assume this is default, not changeable now)
Include recent activity stories
It doesn't feel like the application should have much of an impact on this though, as we use the application for the other functionality within the page (which is all working fine!).
I've searched for possible issues, and checked the more common ones:
There are no age/geographic restrictions
I've submitted 2 requests to Facebook in case the content is blocked, but no response or change
Any recommendations as to what else to try?
Thanks in advance,
Kev
P.S. I asked this question a week ago but it wasn't well formed - hopefully this is a better attempt, but if you need anything else please do let me know.

Categories

Resources