Do I need to manually create a dynamic link for every product in the e-commerce app while using firebase dynamic link? - firebase

I am using a firebase deep link for my e-commerce application. I am able to create a dynamic link from the console and add a deep link with extra parameters to it. But those parameters are hardcoded.
I can see from the docs that we can create dynamic links using API and SDK. It is suggested in the docs to create a new one every time.
Also, dynamic links created using API or SDK does not show up in the console.
Is there any way to keep the dynamic link same and pass the parameters to it?
I am planning to use the dynamic links in conjunction with the notification. I want to use dynamic links to deep link the notification to a specific screen.
Is there a way to add the extra parameters(e.g. order_id or product_id) to the dynamic link?

Since each of your products is unique, each of them will need a unique dynamic link.
If you want to pass custom values, you typically encode them into the URL as shown here: Add parameter to Firebase Dynamic Links.
For example, if you use the "manually" create URLs you pass in the link parameter of your choice and that would contain your product ID:
https://your_subdomain.page.link/?link=https://www.example.com/product1234&apn=package_name[&amv=minimum_version][&afl=fallback_link]
Note: I put "manually" in quotes there, since building URLs this way is highly automatable; it is just more explicit than the using the API to build the URL.

Related

How to pass data between pages in Next.js?

I have a Next.js app which has multiple pages. Each page has the same bar at the top of the screen which displays some data which is fetched from an internal API using SWR. The issue I am having is that to fetch that data it requires an ID of the logged in user (they log in with Discord via next-auth) and after they have left the first page, that ID value is no longer accessible to me.
I have tired storing it in local storage and session storage, I have tried passing it through other components, but nothing has worked and I am out of ideas of how to fix this. Is there any other way where I can pass a value between pages? Or is there a way I can access the session data again?
If you use this on all pages, you could just add that header into the _app.{js,tsx}(see the docs). In case you don't I suppose you create a layout component and reuse it across these pages.
In the future we might be able to use the new Routing API which allows passing adding Layout components for certain sub-routes. (Check the Layout RFC for more info).
because next js uses the react library so you can pass the data using props or you can use redux as well.
like this:
<Component propName={value}/>

Setting Dynamic deeplink with query param With dynamic link in Firebase Using React Native

I want to set the dynamic deep link with query param. For example, Suppose I've got the following information, Let's say for user1 the URL is https://example.com/res/?appId=67abeuusbev&value=55673 this link will be dynamic. i.e. for user2 it can be https://example.com/res/?appId=67abeuusbev&value=55674. I've set up the Firebase dynamic link. For example, say exampletest.page.link/SYu7 . Now I want to set up the deeplink in such a way that those appId and value (https://example.com/res/?appId=67abeuusbev&value=55674) can be set dynamically as a deep link whenever this link will be clicked from a web browser and based on the respective param values I can handle the link. Is there any way to do the same in the firebase dynamic link? I'm using React Native. Thanks for the consideration in advance.
If you're looking into modify short Firebase Dynamic Links programmatically, then it's currently not possible. The only way to update the parameters configured (i.e. deep link) in a short FDL is through the Firebase console, and only short FDLs created from the console can be edited. Short FDLs created programmatically are not displayed in the FDL dashboard.
As a workaround, you can create long FDL manually - by appending parameters and its values. Note that deep links need to be URL-encoded if it has multiple parameters.
i.e. https://exampletest.page.link/?link=https%3A%2F%2Fexample.com%2Fres%2F%3FappId%3D67abeuusbev%26value%3D55674
You can check if the deep link will be able to carry the parameters configured in it by debugging the Dynamic Link using preview page flowchart.

Firebase dynamic links admin generation or user genaration

I would like to use firebase dynamic links for sharing posts in my app via a link.
I found out that the firebase admin SDK can't generate dynamic links. So that leaves a question: should each user generate a dynamic link each time they want to share a post via link?
If there are 10k posts, a lot of links will be generated.
Having a link like https://myApp.app.link/postID would be more efficient because everybody could use the same URL to share.
Is this possible or should each user generate a personal share link?
Thanks in advance!
There is a REST API that you can use to generate Dynamic Links too. It sounds like you're looking to use that.
If the Admin SDK were to add support for Dynamic Links, it will likely be a fairly thin wrapper around that REST API.

Modify google calendar input form

Because of personal purpose, I wanna modify the event input form (the form showing when clicking add new event on Google Calendar). Specifically, I wanna add some fields to this form. Can we do this? If we can, can you suggest what we should use to do this?
Many thanks for supporting.
You can't directly change that form, but you could create a Calendar add-on. As it's stated in the documentation:
G Suite add-ons are built using Apps Script, and their interfaces defined using the Apps Script Card service.
You will be able to create the custom interface you desire using Card service and use Apps Script to create the custom process you want.
Building Google Calendar interfaces has more details about how you could build your interface and Calendar actions has some examples of how you could handle the actions after clicking a button in your custom interface.

Filtering and routing twitter messages

I normally use twitter both as a communication chat and as a short blog service. On my wordpress blog, I import the twitter messages timeline from one twitter account (specific for the blog-visible messages). For communication and chatting, I use another twitter account.
Having two account is a solution, but my geeky nature would prefer to have only one account, with the following magic: every message containing a special tag (e.g. "#blog") will appear on my wordpress blog page. Everything else will not appear on the blog.
Is it achievable with the standard twitter API? does something like this already exist for wordpress? The technical solution would be equivalent to a search for a tag only on a specific user's messages, something that, as far as I see, is currently not possible.
Thanks.
You'll want to use the twitter search API. Use this url to pull the data that you want to display:
http://search.twitter.com/search.xml?q=%23blog&from=mikeluby
You can change the .xml to .json if you want the query to return in json. Remove the ".xml" to get the normal search page to test out the query. Obviously you'll want to change "mikeluby" (my twitter username) to your username.
Update: There may be an issue with the xml return currently on twitter. I would check to see if it works for you. If it doesn't I would suggest switching to the json return or waiting until the problem is fixed.

Resources