The Summary Revenue Report is showing a row of transaction type "CHARGE" with the total volume and charge rate as shown below:
but the transactions are not showing in the Detailed Revenue Report:
any one faced this issue?
aren't we supposed to get all the successful requests in the detailed report?
Solved! Go to Solution.
Ah, OK, to see the actual transactions and dates, you can use the Management API for "transaction-search". The response includes a lot of meta data, so you will need to filter the results, as I've shown using JQ.
You can eliminate the "devCriteria" and get results for all developers, just wanted to show it as an example.
curl -n -X POST \ 'https://api.enterprise.apigee.com/v1/mint/organizations/{{ORG}}/transaction-search?size=100' \ -H 'Content-Type: application/json' \ -d '{ "billingMonth": "AUGUST", "billingYear": 2019, "devCriteria": [{ "id": "{{devId}}", "orgId": "{{ORG}}" }], "transactionTypes": [ "PURCHASE", "CHARGE", "REFUND", "CREDIT" ] }' > results.json
Then using JQ:
$ cat results.json | jq '.transaction[] | { type: .type, rate: .rate, startTime:.startTime, ratePlan_displayName:.ratePlan.displayName, developer_email:.developer.email, product_id:.product.id, application_name:.application.name }' ... { "type": "CHARGE", "rate": 0.05, "startTime": "2019-08-09 15:39:26", "ratePlan_displayName": "pingstatus-all-starter", "developer_email": "developer+app@any.com", "product_id": "pingstatus-v2-product-prod", "application_name": "kurt-app-prepaid" } ...
I've noticed this in the UI and I think its been reported as a bug, but I'll check.
Note the use of showTxDetail and showSummary below.
You can use the Management APIs to get the details, for example, to get a revenue-report:
curl -n -X POST \ https://api.enterprise.apigee.com/v1/mint/organizations/{{ORG}}/revenue-reports \ -H 'Content-Type: application/json' \ -d '{ "fromDate": "2019-08-01 00:00:00", "toDate": "2019-08-31 00:00:00", "showTxDetail": true, "showSummary": true, "showEntityId":false, "transactionTypes": [ "PURCHASE", "CHARGE", "REFUND", "CREDIT" ], "currencyOption": "LOCAL", "groupBy": [ "PACKAGE", "PRODUCT", "DEVELOPER", "APPLICATION", "RATEPLAN" ] }'
Not sure exactly what the difference between a revenue and billing report it, but you can also generate a billing-report, for example:
curl -n -X POST \ https://api.enterprise.apigee.com/v1/mint/organizations/demo29/billing-reports \ -H 'Content-Type: application/json' \ -d '{ "fromDate": "2019-08-01 00:00:00", "toDate": "2019-08-31 00:00:00", "billingMonth": "AUGUST", "billingYear": 2019, "showTxDetail": true, "showSummary": true, "showEntityId":false, "transactionTypes": [ "PURCHASE", "CHARGE", "REFUND", "CREDIT" ], "currencyOption": "LOCAL", "groupBy": [ "PACKAGE", "PRODUCT", "DEVELOPER", "APPLICATION", "RATEPLAN" ] }'
Hope that helps.
hi @Kurt Googler Kanaskie, thank you for your response, i have tried the API request and got the Summary Revenue Report only while showTxDetail is set to true!
Reporting Period:,From:,2019-09-15, To:,2019-09-25
API Product:,All
Developer:,All
Application:,All
Currency:,Local
Type of Report:,Summary Revenue Report
...... | Application Name | Total Volume | Charged Rate | Tax on Rate | Developer Email |
...... | app1 | 150 | 4.3750 | chawki.matta.... | |
...... | app2 | 7 | 0.3500 | chawki.matta |
if we set the showSummary to false we get the below error:
{ "code": "mint.noSuchResource", "message": "Did not find any Transaction that matches the search criteria", "contexts": [], "cause": { "message": "Did not find any Transaction that matches the search criteria", "contexts": [] } }
*** what i want is showing the 150 request details for ex: Charged Rate distribution and date of request. is that possible ?
Ah, OK, to see the actual transactions and dates, you can use the Management API for "transaction-search". The response includes a lot of meta data, so you will need to filter the results, as I've shown using JQ.
You can eliminate the "devCriteria" and get results for all developers, just wanted to show it as an example.
curl -n -X POST \ 'https://api.enterprise.apigee.com/v1/mint/organizations/{{ORG}}/transaction-search?size=100' \ -H 'Content-Type: application/json' \ -d '{ "billingMonth": "AUGUST", "billingYear": 2019, "devCriteria": [{ "id": "{{devId}}", "orgId": "{{ORG}}" }], "transactionTypes": [ "PURCHASE", "CHARGE", "REFUND", "CREDIT" ] }' > results.json
Then using JQ:
$ cat results.json | jq '.transaction[] | { type: .type, rate: .rate, startTime:.startTime, ratePlan_displayName:.ratePlan.displayName, developer_email:.developer.email, product_id:.product.id, application_name:.application.name }' ... { "type": "CHARGE", "rate": 0.05, "startTime": "2019-08-09 15:39:26", "ratePlan_displayName": "pingstatus-all-starter", "developer_email": "developer+app@any.com", "product_id": "pingstatus-v2-product-prod", "application_name": "kurt-app-prepaid" } ...
batchSize | 3 |
ratedVolume | 3 |
startTime | 2019-09-16 06:40:01 |
endTime | 2019-09-16 06:40:05 |
type | CHARGE |
rate | 0.15 |
Hi @Chawki MATTA, answers to your questions:
The revenue report does show that, see attached screenshot comparing results from revenue-reports and billing-reports.