# observe\_rsc\_get\_raw/3

Source: https://zotonic.com/docs/2758/observe_rsc_get_raw-3

URI: https://zotonic.com/id/2758

Language: en



Convert raw stored resource data to its current representation.

Use this notification for resource migrations, including changes to property structures and serialization formats, such as converting legacy `props` values to JSON-friendly structures for `props_json`.

Type: [foldr](/id/doc_developerguide_notifications#notification-foldr)

Runs after decoding stored properties, before caching and `rsc_get`. It also runs when the database layer reads existing `rsc` properties to merge an update; that accumulator contains only custom properties, without database columns (`is_props_only = true`). Full raw resource reads set `is_props_only = false`.

Observers must be idempotent and only convert stored data. Every returned value must be suitable for saving in the `rsc` record. Do not add computed fields, request-specific values, or perform database writes. Use `rsc_get` for computed fields. Reads themselves do not persist the conversion.

`#rsc_get_raw{}` properties:

- id: `m_rsc:resource_id()`
- is\_props\_only: `boolean()`, defaults to `false`. `true` means only the merged `props`/`props_json` properties; `false` means the full raw resource record.

License: 

Attribution: 

Related resources: https://zotonic.com/api/agent/related/2758?language=en


## API access

- [API help](<https://zotonic.com/api-help>)
- [OpenAPI specification](<https://zotonic.com/openapi.json>)
- [This resource as JSON](<https://zotonic.com/api/agent/resource/2758?language=en>)
