Manually change change user .metadata.creationDate in firebase - firebase-authentication

I have IAP with trial period (2 weeks).
So I need to demonstrate it to apple review team.
But I can't because I create a user to their review and for this user 2 weeks trial period not end & it's far from it :)
Can anybody tell me please, how can I change this user's .metadata.creationDate firebase to make available demonstration of my IAP?

The creation date of a user is set by Firebase Authentication when it creates that user record, and cannot be modified.
You will either have to create another user for the test, store a separate creation date somewhere that you control, or create an exception for this specific user's UID in your code.

Related

Paypal rest api express checkout with no shipping field (WebProfile handling)

I'm using Paypal rest api to make payment
the workflow is:
Create payment
Redirect to approval Url
User approved (return back to my site)
Execute payment
But there's one thing that I don't want users re-filling shipping address again because it was filled in my website.
So I change the workflow to:
Create web profile (set no shipping field)
Get web profile ID
Create payment with experienceProfileId given
Redirect to approval Url
User approved (return back to my site)
Execute payment
But I found this will create a lots WebProfile every time user request payment.
I think it is crazy to do:
create and delete it later again and again
attempt listing WebProfiles and check which is the one I want to use every time while creating payment
store experienceProfileId as a constant
What is the best practice for handling WebProfile or does there any solution just hiding shipping address while user approving payments?
Maybe this is not the answer regarding this "WebProfile". As a fact, I dont know what exactly "WebProfile" does or is.
I worked on the same Workflow these days. As you wrote I needed to predefine some address. For me it was obvious, that I have to do the database-stuff on my Website. Then I exactly define the order, shipping_address, etc. and send the users to Paypal.
If you predefine the new ShippingAddress() to your ´new ItemList()´ by
$itemlist->setShippingAddress($shippingaddress) the user cannot change it within the Process.
http://i.imgur.com/nAg8jxU.png
Maybe this helps you a little.

Log in with a specific username with Google API

I am developing a web app for a group, and I want to be able to let anyone in the group create an event and add it to the group's calendar through the app. I was able to get the basic functionality working using Google Calendar API v3 for Javascript -- you could fill out a form with the event's start/end times, title, information, etc, and it could insert that event into the calendar.
But the problem is with authentication. If a user is logged in to a Google account that is not given permission to create events on the calendar, they are unable to add the event (Javascript writes "Forbidden" to the console). If I log out of all Google accounts and then sign in with the account that owns the calendar, the event is created with no problems (that makes sense).
Adding every single person in the group to the edit-permissions on the calendar seems like too much of a "brute force" method.
Is there a way to always authenticate the Google account that owns the calendar? Or, better yet, is there a way just to force authentication in general, even if someone is already logged in to Google / authorized to the app? Some people in the group know the calendar login/password, so if I could always bring up a Google login screen, they could just enter the calendar account information and then add the event from there. Again, I'm using Javascript (not much documentation on this...).
Thanks!
Have a look at Service Accounts. That way the calendar is owned by the application, and so the application will always have permission to update it.
If you want to avoid authentication problem from other opened session in user browser, you have to authenticate on the calendar, using server side library.
check this link:
https://developers.google.com/google-apps/calendar/auth
it bounces you from one article to other, but at the end you should get all information.

User Notifications in Laravel 4 App

In the event management app I am building I require user notification functionality. Having never implemented something like this before, I am after some advice on how you would go about doing this.
Here are a couple of scenarios that will require notifications.
Scenario 1:
Each event in the system has a start date associated with it. If the event also has delegates assigned to it that have a status of 'Provisional', I would like to send a notification 3 days before the event start date to any users with the role 'Admin', informing them that there are still provisional delegates assigned to this event.
Scenario 2:
There are accounts in the system, and each account has an account manager assigned to them. Accounts can also have multiple contacts associated with them. An account manager is able to assign a note to the account which is tied to a contact. So they can, for example, create a note of the type 'Scheduled Call'. The scheduled call has a date and time associated with it, so if around 1 day before I would like to send a notification to the account manager, informing them that they have a scheduled call due for this contact at the specified date and time. I'd like to keep sending or showing this notification until it is dismissed or deleted.
Summary:
There are several other scenarios but these 2 cover the basic functionality. I guess my question is this, has anyone implemented this or can anyone tell me how you would go about implementing such functionality in Laravel 4?
Specific questions are:
Method of Implementation
How to Automatically Check for these Specific Scenarios. Cron or via IronMQ or similar?
Where to store the code. In a helper function or it's own controller?
Are there any other considerations I have missed? Thanks.
I think you would need some sort of scheduled task / CRON job. Using the scheduled task, you can then run php artisan YOUR_CUSTOM_COMMAND. Obviously you would need to develop your own commands to use. See: http://laravel.com/docs/commands

Error trying to create itunes app store test user; Could not convert Apple ID account to iTunes store account

What I am trying to do:
create a test user for testing in app purchase in my app.
What I am doing:
Logging into itunes connect.
Clicking on Manage Users
Clicking on Test User
Filling out the form.
What Error I am getting:
Could not convert Apple ID account to iTunes store account.
Doesnt seem to matter how I fill that form out I keep getting the above error. What am I doing wrong?
If I then try and resubmit the form again i get:
The email address you entered already belongs to an existing Apple account. Please try again.,
However when I look at my users it tells me I dont have any and when I try and use one I created it doesn't let me.
I had accepted all agreements, and apparently time heals all wounds because as of 11/19/2011 its back up and working.
I had this problem today as well. When I went to go create a test user this morning, it would give me the same error. Just a few minutes ago I thought I'd give it another try and when I logged in, I noticed that I needed to accept a new agreement amendment (which I had forgotten to do this morning). After accepting the agreement, I was then able to create a test account without any issues.
I switched Country to United States - and it helped me to fix the issue & to create in-app test user.

Getting ARB subscription information from Authorize.net using Active Merchant?

I'm trying to write a test to verify the start date and interval of an Authorize.net ARB subscription created via Rails + Active Merchant.
I can successfully create the sub using response = GATEWAY.recurring(...) and a I get a success code.
After the subscription is created, however, as far as I can see from the Active Merchant documentation I can't really request any info, like the start date for instance.
The only methods available for ARB are:
cancel_recurring recurring update_recurring
Am I missing something obvious?
The ARB API offers very limited reporting functionality. In fact all you can get through that API is the status of a subscription (ARBGetSubscriptionStatusRequest). The only other options available to you are to create (ARBCreateSubscriptionRequest), update (ARBUpdateSubscriptionRequest), and delete (ARBCancelSubscriptionRequest). This is not a RoR limitation. This is an API limitation. You can confirm this in the ARB Guide.
So, any information you want to keep track of related to a subscription (start date, end date, amount, etc) will need to be recorded by you in your database.
Authorize.Net does have a new Transaction Detail API which they are consistently enhancing. But as of right now it does not report the kind of information you are looking for.