Amazon-Cloudwatch [SOLVED]: Amazon Cloudwatch Logs from External Website

Amazon-Cloudwatch [SOLVED]: Amazon Cloudwatch Logs from External Website

Home Forums Amazon Web Services Amazon Cloudwatch Amazon-Cloudwatch [SOLVED]: Amazon Cloudwatch Logs from External Website

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #197294

    Cloudy Point


    I’m a bit of a AWS newbie so forgive me if this is a stupid question. We have a legacy Classic ASP website (not hosted at Amazon) and I wanted to know if its possible to utilize Amazon Cloudwatch for custom logging. I know we could use a site like Loggly or Sumo Logic but their retention policies are a little short and the pricing a bit too expensive for our small site. But essentially, I’m trying to recreate their functionality in AWS.

    There is quite a bit of detail on how to log from various Amazon services (EC2, etc…) but I’m not finding much on using Cloudwatch from a non-Amazon hosted site

    Basically, I want to SERVERXMLHTTP POST a json log string from our Classic ASP site to Cloudwatch. However, I’m struggling to find the right endpoint and how to post to a particular Log Group that I’ve created. Do I use


    to try to post json like this

         "MetricName": "404 Error",
         "Timestamp": "Wednesday, June 12, 2013 8:28:20 PM",
         "Value": "",
         "Unit": "Count"

    Also, how do I post the json to a particular log group / log stream that I’ve created? Do I authenticate with some sort of

    xxx.setRequestHeader "Authorization", "Basic " & [auth credentials] 


    Thanks for any help!


    Cloudy Point

    Accepted AnswerAnswer

    You can find the list of AWS endpoints here:

    The authentication is done with signed requests:

    When you send HTTP requests to AWS, you sign the requests so that AWS can identify who sent them. You sign requests with your AWS access key, which consists of an access key ID and secret access key.

    And about the specific API call to put the log probably is PutLogEvents:

    Uploads a batch of log events to the specified log stream.

    And remember there’s a SDK for the browser:

    Author: Diego F. Durán
    Creative Commons License
    This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.