# .auth-cookies.json

Authentication cookies for Apple Developer downloads

## Location

```
~/.cupertino/sample-code/.auth-cookies.json
```

## Purpose

Stores authentication cookies for downloading Apple sample code that requires Apple Developer account access.

## Created By

```bash
cupertino fetch --type code
```

The fetcher reuses the `myacinfo` cookie from the system cookie store (whatever Safari has signed into `developer.apple.com` with). Cookies are mirrored to this file for future runs that don't go through Safari.

## Format

JSON file containing browser cookies:

```json
{
  "cookies": [
    {
      "name": "cookie_name",
      "value": "cookie_value",
      "domain": ".apple.com",
      "path": "/",
      "secure": true,
      "httpOnly": true
    }
  ],
  "timestamp": "2025-11-19T00:00:00Z"
}
```

## Security

⚠️ **This file contains authentication credentials!**

- File is prefixed with `.` to hide it
- Contains sensitive session data
- Should NOT be committed to version control
- Cookies may expire and require re-authentication

## Behavior

- **With cookies**: Sample code downloads run headlessly (faster)
- **Without cookies**: sign in to `https://developer.apple.com/` in Safari, then re-run `cupertino fetch --type code` — the fetcher picks up the cookie automatically
- **Expired cookies**: refresh the Safari sign-in and re-run

## Related

- [sample-code/](../sample-code/) - Sample code directory
- [checkpoint.json](checkpoint.json.md) - Download progress tracking
