Saturday, September 7, 2013

SetCronJob's public REST API launched

After receiving many feature requests for a public API to create, retrieve, update and delete cronjobs programmatically, we were working hard and finally a REST API has been released. This is our first version of API, and we're open to any feature request, suggestion and feedback. Error reporting is more than welcome!

You can read the API documentation here.

With a REST API, you can do many things with your cronjobs without logging in to SetCronJob website. Currently we do support these commands:
  • cron.*
    • cron.list: List all cronjobs under your account
    • cron.get: Get one cronjob's information
    • cron.add: Add a new cronjob
    • cron.edit: Update an existing cronjob
    • cron.enable: Enable a cronjob
    • cron.disable: disabled a cronjob
    • cron.delete: delete a cronjob
    • cron.logs: get your cronjob execution logs.
  • group.*
    • group.list: List all groups under your account.
    • group.get: Get one group's information
    • group.add: Add a new group
    • group.edit: Update an existing group
    • group.delete Delete a group
  • account.*
    • account.edit: Update your account settings, currently we only support changing account's timezone.
  • server.*
    • server.time: Get current SetCronJob server time.
    • server.timezones: List all supported time zones.
You can go ahead and grab your API Key at Account > API key. Each account type has its own daily API request quota, and it's currently the same with your account's points:
  • Free account: maximum 50 requests per day
  • Silver account: maximum 3600 requests per day
  • Gold account: from 7200 requests per day, and it'll be more if your account has more points.
Info: The requests counter will reset after exactly 24 hours from the first API request in a day. For example if you send an API request first time today at 8:00AM, requests counter will be reset at 8:00AM tomorrow.

Tips: If you're testing it and used up all daily quota, just regenerate a new API key, the requests counter will be reset too.

No comments:

Post a Comment