---
title: "Update Resource"
method: PUT
path: "/resources/{id}"
tags: ["Update Resource"]
---

# Update Resource

`PUT /resources/{id}`

Updates an existing learning resource entry. The request body should be a JSON object containing the properties to be updated and their corresponding new values.

## Path parameters

- `id` integer, required

## Request body

- ResourceRequest
  - `category` string — Category
  - `languages` string[] — List of languages
  - `name` string — Resource name
  - `notes` string — Resource notes
  - `free` boolean — True or false for whether resource is free
  - `url` string — Resource url

## Response `200`

Updated resource

- Resource
  - `apiVersion` string — API version
  - `resource` ResourceData
    - `category` string — Category
    - `created_at` string, date-time — Date created
    - `downvotes` integer — Negative ratings
    - `id` integer — Resource ID
    - `last_updated` string, date-time — Date updated
    - `languages` string[] — List of languages
    - `name` string — Resource name
    - `notes` string — Resource notes
    - `free` boolean — True or false for whether resource is free
    - `upvotes` integer — Positive ratings
    - `url` string — Resource url
    - `user_vote_direction` string, nullable — Vote direction of a logged in user
  - `status` string — Status message
  - `status_code` integer — Status code

## Other responses

- `401` — Unauthorized access
- `404` — Resource not found
- `422` — Invalid request

## Changes

- **2026-07-17** `6071d3157f6d` — 1 info
  - added the optional property `resource/user_vote_direction` to the response with the `200` status
- **2020-10-19** `5f6fef2c1be0` — 2 warning, 2 info
  - removed the request property `paid`
  - removed the optional property `resource/paid` from the response with the `200` status
  - added the new optional request property `free`
  - added the optional property `resource/free` to the response with the `200` status
- **2020-05-12** `a1ebd031433f` — 4 warning, 1 info
  - removed the optional property `data` from the response with the `200` status
  - removed the optional property `data` from the response with the `401` status
  - removed the optional property `data` from the response with the `404` status
  - removed the optional property `data` from the response with the `422` status
  - …1 more
- **2020-01-10** `ac7f919a3345` — 3 warning
  - removed the optional property `errors/invalid-credentials` from the response with the `401` status
  - removed the optional property `errors/invalid-credentials` from the response with the `404` status
  - removed the optional property `errors/invalid-credentials` from the response with the `422` status
- **2019-10-25** `7f23dab060e1` — 4 warning, 6 info
  - removed the request property `apiVersion`
  - removed the request property `data`
  - removed the request property `status`
  - removed the request property `status_code`
  - …6 more

[Full history](https://skmtc.dev/operationcode/apis/operation-code-resources-api/changes/resources/:id/put.md)

---

[API](https://skmtc.dev/operationcode/apis/operation-code-resources-api.md) · [All operations](https://skmtc.dev/operationcode/apis/operation-code-resources-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/operationcode/operation-code-resources-api/revisions/6071d3157f6d/schema)
