What URL to use for sharing app on Facebook, twitter,...? - ios

I would like to include a button in my app "share this app'. And then I would popup the
standard UIActivityViewController. I would attach the URL to my app in the app store.
But what URL should I use? Are there any guidelines? I would like that it shows pretty on Facebook, twitter and stuff...

This is a duplicate, already answered this question see the link ..
But you need to have the app on the appstore already so yeah, or you need to be sure of your appname.
EDIT:
Use itms:// instead of http:// for it to open directly in the appstore and not redirect from the browser first

I looked at the post mentioned by Andre Filoppio. It does indeed mention a lot of different URL that could potentially be used. I have been testen them all, the only one that got my nice pretty Facebook mention was:
http://itunes.apple.com/app/idXXXXXXXX (where XXXXX is your app id)
The fancy ones like http://appstore.com/ProductNameWithoutSpacesAndStuff
all have the same problem: they have so many redirects, or open in itunes directly, that Facebook just displays this kind of message "connecting to Itunes store" instead of your app icon with something like "available on the app store"
(sorry guys I had a nice picture, but apparently I don't have enough reputation to post this to this answer)

Related

App Store link using itms-apps: for developer portfiolio

I can open up a page for an app review using the itms-apps:// scheme.
itms-apps://itunes.apple.com/xx/app/id000000000&action=write-review
I have not been able to find a list of possible "action" parameters, other than 'write-review.'
Is there one to show the developer's portfolio?
I would like to direct a customer to my portfolio, but if I use...
https://appstore.com/AbrahamStolk
...as suggested by Apple, then I get an intermediate dialog asking the user if she wants to open the app store, instead of a direct link.
So, it turns out you can do this with itms-apps, but you don't need an action parameter for it. Instead, you build a URL similar to this:
itms-apps://itunes.apple.com/us/developer/abraham-stolk/id303320757
To find your developer id, you can use the iTunes Link Maker.
The use of itms-apps: instead of https: will cause a direct link to the app store, without going through the Safari browser first.

Open App Store 'Featured' page (not a specific app) from a link.

I know that an app can be linked to directly from an URL so that when it is clicked on my phone, the AppStore app will open and guide me to the app in question but is it possible to link to the 'Featured' page (or better still the 'Redeem' page of AppStore from a link?
The scenario is I send a promo code for AppXYZ out in an email and the recipient can click that email link and be taken to (a) the AppStore app or (b) the AppStore app Redeem page passing the code through.
I know the link for something similar in iTunes but not AppStore. Can't seem to find any info other than links to specific apps (which I don't want).
iTunes: itmss://buy.itunes.apple.com/WebObjects/MZFinance.woa/wa/freeProductCodeWizard?code=THE_CODE
Thanks in advance.
If you want to redeem a code on the App Store it nevertheless always goes through the link you provided, but correctly spelled:
itms://buy.itunes.apple.com/WebObjects/MZFinance.woa/wa/freeProductCodeWizard?code=THE_CODE
It opens the iTunes app on iOS with the code filled in, the user still has to tap on redeem as it's still a transaction. If he does so, the app will automatically be downloaded (just tested it with the latest iOS version)
I tried to copy a couple of links from the desktop iTunes and checked, if they work on iOS, but the answer is no. E.g.:
https://itunes.apple.com/us/collection/editors-choice/id25204?fcId=531794418&mt=8
https://itunes.apple.com/WebObjects/MZStore.woa/wa/viewRoom?fcId=1188885481&genreIdString=36&mediaTypeString=Mobile+Software+Applications
https://itunes.apple.com/WebObjects/MZStore.woa/wa/viewRoom?fcId=554381198&genreIdString=36&mediaTypeString=Mobile+Software+Applications
(Also tried it with itms:// instead of https://)

Program UIButton to open Facebook app to specific page, and same for twitter and instagram

I am building an app that when you click a button labeled "Facebook", "Twitter", or "Instagram", it will open the respective app and take you to the specific page I set. I've been searching non-stop for answers for the last week, if anyone can help I would greatly appreciate it!
I have been all over StackOverflow and other forums and videos and cannot find the answer to this question. Either the solutions I find are outdated and do not work anymore or are not exactly what I want.
Please note: typically a question like this is not going to get very useful answers on SO. In the future, try to be more specific and show a little work. However, I appreciate how it can be difficult to search for a solution when you don't know the correct terminology. The term you are looking for is "URL scheme"
Each app has its own URL schemes for opening specific pages and/or websites. You will need to check their documentation and/or search online to see if you can find the URL schemes you need. There was an unofficial website listing a lot of these, but it is no longer maintained.
For example, to open a specific Facebook profile page (could be a person, or a company, etc) use:fb://profile/<page id>" replacing the with the Facebook ID corresponding to the page. This is a numeric value, you can find it sometimes in the URL, but http://findmyfbid.com/ is a useful resource for this.
Then you can simply trigger open on the shared UIApplication instance to open the URL. But keep in mind the user may not have Facebook installed, so you should use canOpenURL to check if the URL scheme you are trying to use is supported, and if not you can just open the URL in a browser.
However, some apps may have implemented the new features for Universal linking, so the device may automatically open the appropriate page if you just provide a standard URL, like https://facebook.com/<page_id>. I suggest playing around with it.
Note, for each URL scheme you want to be able to check canOpenURL with, you will need to add it to your app's plist.
Since I already have Instagram and Twitter handy here are their basic schemes for opening a user's page:
instagram://user?username=<username>
twitter://user?screen_name=<username>
Note: there are other URL schemes that these apps support (e.g. you could link to a location page, or a specific tag, on Instagram) so you should check their documentation for more information on URL schemes.

iOS: How Do I Make a Button To Allow Users To Tell a Friend About My App? [duplicate]

This question already has an answer here:
"Tell Friend" example which allow selection multiple contact
(1 answer)
Closed 8 years ago.
After searching Google for my question, all I could find was Ad-hoc distribution options and tutorials, and it seems the results are over saturated for questions such as mine.
I simply need to make a method in my program that brings up the typical share options (action sheet) to allow my user to select ALL/ANY of the available options to inform his or her contacts about downloading my app, via any means of which the iOS divide is capable.
I'm hoping this can be handled by the iOS since I don't yet know the URL to the App Store to download my app.
EDIT: I'm a bit annoyed with the fact that so many people have rushed to mark this as a duplicate when in fact it is not.
The link to the pre existing question is that of an EMAIL ONLY share option.
As above, i clearly state: "I simply need to make a method in my program that brings up the typical share options to allow my user to select all the available options to inform his or her contacts about downloading my app."
EMAIL IS NOT ALL THE OPTIONS THAT ARE AVAILABLE...!
To use the inbuilt API for the share options like the image below, you will have to import the Social Framework.
Check out the following SO questions:
Question 1
Question 2
Apple Documentation
To address the last part of your question: You can know the URL to your App Store page even before it's in stores.
As soon as you create the app in iTunes Connect, your app is associated with a link that can be found by right-clicking on the "View in App Store" button within your app's iTunes Connect information. When creating your "share options," this is the link you should share in order to link to your page in the app store.
As far as programming the actual sharing goes, you'll need to be more specific about the type of sharing you want to do. If you want to share via Facebook or Twitter for example you'll need to use the relevant SDK/API to do so; if you want to share via email, you can use MFMailComposeViewController or perhaps an SMTP client; if you want to share via SMS, you can use MFMessageComposeViewController or an SMS service like Twilio... all depends...
Edit: Someone just now down-voted this answer, probably just because there was no mention of the action sheet; but the initial question had no mention of an action sheet until 5 days after its post. Like aksh1t said, yes, you can use the Social framework in that case.

FBConnect “via” link broken on feed posts from iOS app

I posted this on regular SO before I found the Facebook-specific one, so hopefully it will get some more love here.
I have an iOS app that is successfully posting to Facebook via the FBConnect SDK. I have registered the app in Facebook as a native iPhone app and filled out the required data (bundle ID, app store id, etc), however I am running into one small, but very annoying issue.
When the app posts to the user's feed, the message has a "via App Name" link that presumably goes to the app store, or somewhere sensible. This link never work, it always goes to a page stating "Page not found", with no helpful information.
The link is of the form: http://www.facebook.com/apps/application.php?id=${app.id}
I have verified that the ID that it is putting in there is in fact my app ID. Can anyone shed some light on what might be causing this and some possible fixes?
It's in Settings/Basic put your URL in the Website and Mobile Web section.
I a normal browser it will use the "Website" url on a mobile platform (iOS, Android, etc) it should use "Mobile Web" url.
You are missing the website config setting for your application. See this for an example:
http://www.facebook.com/apps/application.php?id=204143816348127
Notice facebook displays a message about redirecting the user to a landing page. You need to define a landing page in your app settings for it to use. Otherwise it can't go there.

Resources