Skip to content
Context docs
Resources

Automate a recurring report

By the end of this guide, a weekly sales summary writes itself every Monday morning and is saved in a folder your whole team can open.

Who it’s for

Anyone who writes the same report every week or month, such as a sales lead’s pipeline summary, an operations update or a finance snapshot. The example follows Sam at Juniper Outdoor Co., who summarizes the week’s sales every Monday from a spreadsheet in the team’s Drive.

What you’ll set up

PieceWhat it isExample
TaskOne run by hand, to get the result right“Summarize this week’s sales”
SkillThe report’s format and rules, written once“How we write the weekly sales summary”
AutomationThe schedule, the agent and the instructions“Weekly sales summary”, every Monday at 8:00 AM
Drive folderWhere the data comes from and where the report goesJuniper Weekly Sales, in the workspace drive

Steps

Get one good result first

  1. Put the source data in a workspace folder, such as Juniper Weekly Sales. Files in the workspace drive are visible to everyone in the workspace, so the team can open the report there.
  2. Send the report as a normal task. Type @ in the composer to mention the folder, and say exactly what the report contains. Send a task covers the composer.
  3. Correct the result in the thread until it is right. Then write down what you corrected as a skill. Make it a skill has sample text.

To pull data from a connected app instead, such as a CRM, add the app to the agent’s Setup tab under Connectors. The agent can then use it in every task it runs, including automation runs. Connectors explains whose account it uses.

Create the automation

  1. Go to Home > your workspace > Automations.
  2. Click Create automation. To start from the schedule, open the arrow next to it and choose On a schedule.
  3. Under Automation name, type a name, such as “Weekly sales summary”. Runs are filed into a project with this name.
  4. Under Trigger, click Add trigger > Schedule. Click the schedule to change it: choose Weekly, pick Monday, then set At, Zone and Starting. The row then reads like “Every Monday at 8:00 AM”.
  5. Under Agent, choose who does the work. You can’t change the agent later: an automation keeps the agent it was made with.
  6. Under Instructions, write what the agent should do on each run. Type @ to mention the source folder, and click Attach skills (the scroll) to add your skill. For example:

    Read the newest .xlsx in @Juniper Weekly Sales. Write this week’s sales summary. Save it as a .docx in the same folder, named “Sales summary” with today’s date.

  7. Check Model, Runs on and Runs as. Runs use a cloud sandbox unless you pick one of your paired machines, and they always run with your access.
  8. Click Create automation. It is on straight away.

Attached files and skills work only with a Schedule trigger. With a GitHub event or Another app trigger, remove them or Context won’t create the automation.

Check the first run

  1. On the automation’s page, click Run now to try it without waiting for Monday.
  2. Under Runs, open the run. Each run is a task, so you can read the thread and open the files it saved.
  3. If something is wrong, click Edit, fix the instructions or the schedule, and click Save changes.

Know where results land and who hears about it

  • The report goes wherever the instructions say. Name a folder, or the agent saves it with the run’s own task files instead of in the team’s folder.
  • The runs are listed on the automation’s page under Runs, with each run’s status, and in a project named after the automation.
  • Notifications go to you, the person who created the automation. By default Task completed reaches your Inbox, plus your browser and phone if you’ve turned on notifications there, but not your email. Task failed also sends an email straight away. To change this, go to Settings > Notifications > Configure events.
  • Teammates are not notified. They find the new report in the shared folder.

Pause, change or delete it

  • Pause stops the runs, and Turn on starts them again.
  • Edit changes the name, schedule, instructions, model or machine. The agent stays the same.
  • The trash icon deletes the automation. Context asks “Delete this automation?” first. It stops running and leaves the list, and its past runs stay in your task history.

Each run uses credits, so pause reports nobody reads.

Make it a skill

Keep the format in a skill and keep the automation’s instructions short. When the format changes, you edit the skill once, and the next run uses it. To create one, follow Create a skill. Sample text:

Code
Name: How we write the weekly sales summary What it's for: Use this when writing Juniper Outdoor Co.'s weekly sales summary from the weekly sales spreadsheet. Steps: 1. Find the newest weekly sales file and last week's file in the folder you are given. 2. Compare this week with last week: total sales, units, and average order value. 3. List the top five products by sales, with each one's change from last week. 4. Flag any product or region that moved more than 20%, with one line on the likely reason if the data shows it. 5. End with three bullet points: what went well, what to watch, what to do next. Rules: - One page. Plain sentences. No jargon. - Show money in USD with no decimals, and changes as percentages. - If a file is missing or a number looks wrong, say so at the top. Do not guess. - Save as a .docx named "Sales summary YYYY-MM-DD" in the folder you are given.

Tips

  • Say everything in the instructions. A run can’t ask you questions, so name the folder, the file type and the file name. Automations has more on this.
  • Put the date in the file name, so each week’s report is kept and nothing is overwritten.
  • Check the agent’s permissions. Nobody watches a scheduled run, so an agent whose preset asks before it edits Drive or uses a connected app can hold up the report. Test with Run now first. If the run asks for approval, answer it from Inbox > Needs you, and consider a preset that allows what the report needs. See Agent permissions.
  • Read the run’s status. A run that couldn’t start shows Did not start under Runs. For example, if the paired machine it runs on is offline, that run doesn’t start and the schedule tries again at its next time.
  • Check the time zone when your team is in several countries.
  • Use the Calendar view on the Automations page to see when each report runs.

Next steps