> For the complete documentation index, see [llms.txt](https://help.codegrade.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.codegrade.com/setup-assignment/build-assignment/creating-an-assignment/in-sakai.md).

# In Sakai

Creating a new CodeGrade assignment from within Sakai will correctly add this assignment to the corresponding course in CodeGrade, a new course will automatically be created in CodeGrade if it does not yet exist in CodeGrade. Follow the steps below to create a new CodeGrade assignment in Sakai:

1. In your Sakai course, navigate to the "**Resources**" page, which can be found in the sidebar.
2. Click on the "**Add Content**" button and select "*Add External Tool*" in the list that pops up.
3. In the External Tool Selector, select "*CodeGrade*".
4. Now, you can provide the *Tool Title* (name of the assignment) and *Button Text* and press "**Save**".

{% hint style="success" %}
A good practice is to keep the Tool Title and Button Text the same!
{% endhint %}

{% hint style="success" %}
Grades are automatically sent back to Sakai after setting [the **assignment state** to **Done** in CodeGrade.](/faq/releasing-grades-and-feedback.md) While the assignment is in the **Done** state, all grades and changes to grades are immediately sent back to Sakai. Only after this is done, the CodeGrade assignment will show up in the gradebook.
{% endhint %}

Now, go ahead and set up the General Settings:

{% content-ref url="/pages/F0zZ1aj7XLlwCqbDZYOz" %}
[General settings](/setup-assignment/build-assignment/general-settings.md)
{% endcontent-ref %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://help.codegrade.com/setup-assignment/build-assignment/creating-an-assignment/in-sakai.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
