Skip to content
Back to skills

Cairo Type Serialization

ASecurity

Explain Starknet ABI serialization of Cairo types, including arrays, structs, enums, and integers; use when a request involves calldata encoding or Serde behavior.

  • 2 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 27, 2026
documentation

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned September 27, 2026

npx -y skills add David-Li0406/meta-skill-evloving --skill cairo-type-serialization --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Cairo Type Serialization?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Cairo Type Serialization
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/david-li0406-cairo-type-serialization/badge)](https://www.skillsdirectory.com/skills/david-li0406-cairo-type-serialization)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: cairo-type-serialization
description: Explain Starknet ABI serialization of Cairo types, including arrays, structs, enums, and integers; use when a request involves calldata encoding or Serde behavior.
---

# Cairo Type Serialization

## Overview
Explain how Cairo types are serialized to felt252 values for calldata, events, and storage interaction.

## Quick Use
- Read `references/type-serialization.md` before answering.
- Identify whether a type fits in one felt or requires multi-felt encoding.
- Use Serde-derived behavior as the default.

## Response Checklist
- Mention length prefix for arrays and spans.
- Explain enum encoding as variant index plus payload.
- For multi-limb integers, state the limb ordering.

## Example Requests
- "How is a u256 serialized in calldata?"
- "How does enum serialization work?"
- "What does ByteArray serialize to?"

Files in this skill

  • SKILL.md871 B
  • references/type-serialization.md957 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…