Logging sessions in google sheets / airtable

For general discussion of the Poker Mavens software
Post Reply
omernesh
Posts: 24
Joined: Tue Apr 14, 2020 9:37 am

Logging sessions in google sheets / airtable

Post by omernesh »

Hey,

Has anyone been able to log the server's activity in google sheets / airtable?
I'd love to get some pointers on where to begin.

Thanks.
Imop4444
Posts: 2
Joined: Thu Oct 22, 2020 2:52 am

Re: Logging sessions in google sheets / airtable

Post by Imop4444 »

If you want to try coding this, the LogsEvent poker mavens API call be used: https://www.briggsoft.com/docs/pmavens/PMHelp.htm

Otherwise, you could use a tool like integromat or zapier to automate this without code. Keep in mind their free tier might not last long depending on the size of your logs.
---

I threw something quick together with integromat that dumps the logs into google sheets:

1. Enable the poker mavens API from the poker mavens desktop app

Make sure you set an API password.

Then test the API is accessible by visiting this URL in your browser http://yourpokersite.com:8087/api?Passw ... 2021-08-08

For extra security, you can "whitelist" integromat's IP addresses so that only they can access your API (https://www.integromat.com/en/help/allo ... integromat):
---
Hope that helps!
Image

2. Create an integromat account
Here's my referral link :) https://www.integromat.com/?pc=imop44

3. Create a new "scenario"

4. Add a "HTTP" action
- Fill in the URL of your poker mavens server
- Under the "Password" query parameter, enter in your poker mavens API password
- The "Date" query parameter is the date to extract log entries for. In my picture below, it's using the current date, but you can enter in previous dates to backfill the spreadsheet.

Image

5. Extract the individual log lines

Connect the "HTTP" action to a "Text Parser" action:

Image

6. Add the log entries to a google sheet
- Add a "Google Sheets" action, which will prompt you to sign-in to google and select a spreadsheet:

Image

7. Save/Test the scenario
Test that the log entries are added to the spreadsheet

8. Filter out invalid lines
The first 3 lines of the API response aren't actually log entries. They can be filtered out by clicking on the connection between "Text Parser" and "Google Sheets", and entering:

Image

9. Schedule the spreadsheet to be updated daily

Click the clock on "HTTP" and schedule daily:

Image

Adjust the "Date" Query String parameter to use the previous day, so that you fetch all of that day's logs:

Image
--

Hope that helps!
omernesh
Posts: 24
Joined: Tue Apr 14, 2020 9:37 am

Re: Logging sessions in google sheets / airtable

Post by omernesh »

thanks man,
This is a great help. Appreciate it.
Post Reply