[MUSIC PLAYING]
SPEAKER 1: After building an API with Apigee
and sharing it with developers, there's
still work to be done to make sure that everyone
has a successful experience.
As an API producer, you may want to know critical information
like how is my API traffic trending over time,
when is API response time fastest or slowest,
and who are my top developers?
The answers to these questions can help you improve your APIs,
troubleshoot problems, and make better decisions
for your business.
This is where Apigee Analytics comes into play.
Apigee Analytics collects and calculates
a wealth of information that flows through API proxies.
You can visualize this data in the Apigee
UI with predefined analytics dashboards,
as well as custom reports.
Apigee Analytics can help improve the API experience
for everyone.
This data can help provide insight to the API team
about how the API program is doing overall,
how individual APIs are doing, and how to improve
and debug APIs.
Analytics information can also be
shared with app developers, who will
want to know how to improve their apps to increase revenue.
The operations team can learn more about traffic patterns
and when to add back-end resources
or make other adjustments.
And the business owner can see whether or not
their initial API investment is paying off.
In other episodes, we learned how to build an API proxy,
secure APIs with API keys, and set up a developer portal.
In this episode, we'll take a tour of Apigee Analytics
and learn how it can help you troubleshoot customer issues.
First, visit apigee.google.com to open the Apigee UI.
As you can see, we've already created some API proxies
and generated some traffic against them.
In the left Navigation bar, click Analyze, and then
API Metrics.
This shows you Apigee's pre-built analytics dashboards
for API proxy performance, cache performance, error code
analysis, latency analysis, and target performance.
API proxy performance gives you information
about the performance of your proxy over a period of time.
You can see how much overall traffic you've had,
including whether it resulted in success or failure.
There's also average response time in milliseconds.
You can also view analytics for a specific proxy.
Next up, there's cache performance,
where you can see the cache hit rate, the number of cache hits,
and cache response times.
You can also take a look at error code analysis,
where you can learn about how many errors occurred
and what types of errors they were.
Here we have 60 errors that were 404, meaning not found.
There were also 30 errors that were 401, meaning unauthorized.
These likely happened because the caller did not
provide a valid API key.
Now, let's take a look at latency analysis.
First, select a time range of the last hour.
We'll select an API proxy to look at.
Here we can see some statistics about response time.
At 3 o'clock in the afternoon, the 99th percentile
was 97 milliseconds, meaning that 99% of API calls
were faster than 97 milliseconds.
We can also see that 95% of API calls
were faster than 14 milliseconds.
And of course, the median response time
was just two milliseconds.
You can analyze response time by the target as well as
requests and response processing latency.
There's also a Target Performance dashboard
to see how fast the back end system is
responding to your requests.
This can help you understand when
you might want to use caching.
Beyond API metrics, you can also learn more
about the developers that are using your APIs.
Under Developers, can click Developer Engagement.
Here you can see the total number of developers,
the number of developers with apps,
and the number of active developers.
You can also browse details about individual applications
the developers have registered using the Developer portal.
Here we have two apps--
one for stackdriver monitoring and another for ping stats.
For each of these apps, we can see the email of the developer
as well as traffic and error statistics.
There's also a traffic composition section,
where you can take a look at your top 10 API proxies
by amount of traffic.
In this case, the vast majority of API proxy traffic
is for ping status V1.
You can also take a look at your top 10 developers
by amount of traffic, top 10 products by amount of traffic,
and top 10 apps by amount of traffic.
There's also an End Users section,
where you can see the types of user agents
that are accessing an API proxy.
In this case, we have some cURL calls as well as
some library calls via Postman.
Finally, there's a geo-map that allows us to see
traffic broken down by country.
Here we can see that most of our traffic
is coming from the United States,
but we also have some traffic from Singapore, Belgium,
and Brazil.
In addition to the pre-built Analytics dashboards,
you can also create custom reports.
Here we have a custom report where
we can see traffic broken down by application.
If you select an application, you
can also see the breakdown of traffic by API call.
You can also expand the time frame beyond the current day.
If you want to expand beyond the listed maximum of 14 days,
you can submit a job to handle report generation
asynchronously in the background.
You can come back later to see the results of this custom
report.
As you can see, Apigee Analytics comes packed with helpful data
visualizations.
One key use case for these visualizations
is troubleshooting.
Data visualization is a powerful way
to unlock, compare, contrast, and assess
the underlying data that Apigee collects about your APIs.
Perhaps you've recently received some feedback from a customer
that one of your APIs is being slow.
Apigee Analytics can help you figure out
exactly what's going on.
You can check to see if the slowness is being seen by just
one app or multiple apps.
If it's just being seen by one app,
there may be a problem with that app.
You can also look to see if the slowness is concentrated
in a certain geolocation, which may suggest a network problem.
If neither of these is the case, then you
might have a problem with Apigee and may
want to look at policy configuration.
It may also be helpful to compare the average response
time of different APIs to see if one of them
is significantly underperforming the others.
And finally, you could generate a custom report
to visualize maximum latency time by app and resource.
Thanks for joining us to learn more about Apigee Analytics--
a powerful tool to help you visualize
API data to gain insights that can help
drive business success.
And friends, if you found this episode helpful,
please click the Like button and subscribe to the channel.
Cheers.