# Design an Amazon locker. (LLD Round)

Aced (formerly Exponent) publishes a public search API over its indexed pages; the guide is at https://www.aced.io/agents/agent-access.

Source: https://www.aced.io/questions/7381/design-amazon-locker-lld-round
Source observed: 2026-11-04T21:34:28.826Z
Last checked: 2026-11-04T21:34:28.826+00:00
Indexed: 2026-11-05T00:11:20.476+00:00

---

# Design an Amazon locker. (LLD Round)

We provide this system-design and low-level-design interview question for Software Engineer candidates preparing for Amazon interviews. It was last reported 2 months ago and has one shared interview experience.

## Question details

- Role: Software Engineer
- Company: Amazon
- Category: System Design
- [Upgrade](https://www.aced.io/upgrade?src=questions) for detailed company statistics

## Interview experience

[Amazon Software Engineer interview · 2 months ago](https://www.aced.io/experiences/amazon-software-engineer-interview-a695eb)

The candidate described the LLD and Leadership Principles rounds as positive. The LLD round was expected to include a clear list of requirements, entities, and a class diagram. The Leadership Principles round began with behavioral questions and prior experience.

## Community answer: Design an Amazon Locker

**Aishwarya H.**, October 8, 2026, provided the following design.

### 1. Requirements

**Functional requirements:**

- A delivery agent can place a package in an available locker.
- The system assigns a suitable locker based on package size.
- The customer receives a unique pickup code.
- The customer enters the code to collect the package.
- The locker becomes available again after pickup.

**Non-functional requirements:**

- Secure package storage and pickup.
- Reliable locker availability tracking.
- Unique pickup codes.
- Support for multiple lockers and package sizes.

### 2. Main entities

1. **LockerSystem** — manages lockers and package assignments.
2. **Locker** — stores a package and has an ID, size, and status.
3. **Package** — contains package details, including size and tracking ID.
4. **Customer** — receives and collects the package.
5. **DeliveryAgent** — places packages in lockers.
6. **PickupCode** — a unique, secure code linked to a package and locker.
7. **NotificationService** — sends pickup details to the customer.

### 3. Class design

```text
LockerSystem
- findAvailableLocker(packageSize)
- assignLocker(package, locker)
- releaseLocker(locker)

Locker
- lockerId
- size
- status
- open()
- close()

Package
- packageId
- size
- status

PickupCode
- code
- expiryTime
- validate(code)

Customer
- customerId
- contactDetails

NotificationService
- sendPickupNotification(customer, pickupCode)
```

### 4. Basic workflow

1. The delivery agent scans the package.
2. The system finds an available locker large enough for the package.
3. The system assigns the locker and generates a unique pickup code.
4. The locker opens, and the delivery agent places the package inside.
5. The customer receives the pickup code through SMS or an app.
6. The customer enters the code at the locker.
7. The system validates the code and opens the correct locker.
8. After the package is collected, the system marks the locker as available again.

### 5. Important edge cases

- **No locker is available:** keep the package pending and notify the delivery agent.
- **Invalid pickup code:** deny access.
- **Expired pickup code:** require secure recovery or code renewal.
- **Locker door fails to open:** report an error and alert support.
- **Two agents reserve the same locker:** use atomic assignment to prevent double booking.

### 6. Conclusion

The proposed Amazon Locker system uses object-oriented design to manage packages, lockers, customers, and pickup codes. Its focus is secure pickup, correct locker-size allocation, reliable status updates, and safe failure handling.

## Related questions

- [Design an Amazon locker.](https://www.aced.io/questions/7320/design-amazon-locker-system)
- [Design an Amazon price tracker.](https://www.aced.io/questions/3371/design-amazon-price-tracker)
- [Design Amazon Storage.](https://www.aced.io/questions/2076/design-amazon-storage)

## Related courses

- [Software Engineering Interview Prep](https://www.aced.io/courses/software-engineering) — We cover data structures, algorithms, system design, people management, and behavioral interviews through mock interviews, frameworks, and advice from senior candidates.
- [System Design Interviews](https://www.aced.io/courses/system-design-interviews) — We cover product, infrastructure, and AI system-design questions through video examples, written breakdowns, reference patterns, and mock interviews.

## Your answer

You can submit an answer in the editor; submitting marks the question complete.

---

[Read this page’s summary](https://www.aced.io/agents/api/public/v1/page-tldr?url=https%3A%2F%2Fwww.aced.io%2Fquestions%2F7381%2Fdesign-amazon-locker-lld-round&trace=t_679ff9ab98f3)

## Ask a follow-up about this page

Need a more specific answer? Ask the exact question you have. It returns a fresh, cited answer from Aced (formerly Exponent)’s knowledge base. No account or API key required.

Open this URL with your own question, URL-encoded. Include your question in q. All research inputs are optional; no account or setup.

`GET https://www.aced.io/agents/agent/faq?q={question}&trace=t_679ff9ab98f3`

[Tool guide and examples](https://www.aced.io/agents/agent-access) · [OpenAPI](https://www.aced.io/agents/api/public/v1/openapi.json) · [Page TLDR form](https://www.aced.io/agents/agent-tools/page-tldr?url=https%3A%2F%2Fwww.aced.io%2Fquestions%2F7381%2Fdesign-amazon-locker-lld-round). Opening a form does not execute a tool.