# social.grain.repo.uploadBlob

> Upload a blob to the logged-in account's PDS, for a record written after to reference. Called as social.grain.repo.createRecord is.

- Kind: procedure
- Authority: repo.grain.social
- Lexicon: 1
- Published by [grain.social](https://lexicon.garden/identity/did:plc:e7rftrdyz5e2rw4y6ocszew2), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.repo.uploadBlob)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.repo.uploadBlob/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.repo.uploadBlob/analytics)

## Procedure (`social.grain.repo.uploadBlob`)

Type: procedure · POST

### Input (*/*)


### Output (application/json)

- `blob` (blob, required)

### Errors

- `ScopeMissingError`: The account's PDS granted the session less than the upload needs.

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "Upload a blob to the logged-in account's PDS, for a record written after to reference. Called as social.grain.repo.createRecord is.",
      "errors": [
        {
          "description": "The account's PDS granted the session less than the upload needs.",
          "name": "ScopeMissingError"
        }
      ],
      "input": {
        "encoding": "*/*"
      },
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "blob": {
              "type": "blob"
            }
          },
          "required": [
            "blob"
          ],
          "type": "object"
        }
      },
      "type": "procedure"
    }
  },
  "id": "social.grain.repo.uploadBlob",
  "lexicon": 1
}
```
