Skip to content

Collections

Collections are the content types in Portfolio CMS. Each collection stores a specific type of data that appears on your portfolio.

Overview

CollectionPurposeKey Fields
UsersAdmin accountsEmail, password, roles
MediaFile uploadsFile, alt text, dimensions
CategoriesProject groupingName, slug, color
ProjectsPortfolio itemsTitle, description, images, tech stack
SkillsTechnical abilitiesName, category, proficiency
ExperienceWork historyCompany, role, dates
EducationAcademic historyInstitution, degree, dates
AchievementsAwards/certsTitle, issuer, date
TestimonialsClient feedbackQuote, author, rating
CompaniesClient logosName, logo, website
MessagesContact submissionsName, email, message

Projects

The main collection for showcasing your work.

Fields

FieldTypeDescription
titleTextProject name (required)
slugTextURL-friendly identifier
descriptionTextareaBrief overview
contentRich TextDetailed write-up
featuredImageUploadMain project image
galleryArrayAdditional screenshots
categoryRelationshipLink to Categories
technologiesArrayTech stack used
liveUrlTextDemo/live site link
repoUrlTextSource code link
featuredCheckboxShow on homepage
orderNumberDisplay order

Usage Example

typescript
// Fetch featured projects
const projects = await payload.find({
  collection: 'projects',
  where: {
    featured: { equals: true },
  },
  sort: 'order',
  limit: 6,
})

Skills

Technical skills and expertise.

Fields

FieldTypeDescription
nameTextSkill name (required)
categorySelectFrontend, Backend, DevOps, etc.
proficiencyNumber1-100 scale
yearsOfExperienceNumberYears using this skill
iconSelectIcon to display
featuredCheckboxHighlight this skill
orderNumberDisplay order

Categories

  • Frontend
  • Backend
  • Database
  • DevOps
  • Mobile
  • Tools
  • Other

Experience

Work history and professional experience.

Fields

FieldTypeDescription
companyTextCompany name (required)
positionTextJob title (required)
companyLogoUploadCompany logo
companyUrlTextCompany website
locationTextJob location
startDateDateEmployment start
endDateDateEmployment end (if applicable)
currentCheckboxCurrently employed here
descriptionRich TextRole overview
responsibilitiesArrayList of duties
achievementsArrayNotable accomplishments
technologiesArrayTech used in role

Education

Academic background and certifications.

Fields

FieldTypeDescription
institutionTextSchool/university name
degreeTextDegree/certificate earned
fieldOfStudyTextMajor/concentration
institutionLogoUploadInstitution logo
locationTextInstitution location
startDateDateStart date
endDateDateGraduation date
currentCheckboxCurrently enrolled
gpaTextGPA (optional)
descriptionRich TextAdditional details
achievementsArrayHonors, awards

Achievements

Awards, certifications, and accomplishments.

Fields

FieldTypeDescription
titleTextAchievement name (required)
typeSelectAward, Certification, Publication, etc.
issuerTextIssuing organization
dateDateDate received
descriptionTextareaDetails about the achievement
credentialUrlTextVerification link
credentialIdTextCertificate/credential ID
imageUploadBadge or certificate image
featuredCheckboxHighlight this achievement

Testimonials

Client feedback and recommendations.

Fields

FieldTypeDescription
quoteTextareaThe testimonial text (required)
authorNameTextClient/author name (required)
authorTitleTextTheir job title
authorCompanyTextTheir company
authorImageUploadProfile photo
ratingNumber1-5 star rating
projectRefRelationshipRelated project
featuredCheckboxShow on homepage
orderNumberDisplay order

Companies

Clients, employers, or partners to display as logos.

Fields

FieldTypeDescription
nameTextCompany name (required)
logoUploadCompany logo (required)
websiteTextCompany website
featuredCheckboxShow on homepage
orderNumberDisplay order

Messages

Contact form submissions.

Fields

FieldTypeDescription
nameTextSender name
emailEmailSender email
subjectTextMessage subject
messageTextareaMessage content
statusSelectUnread, Read, Replied, Archived
createdAtDateSubmission timestamp

Workflow

  1. User submits contact form
  2. Message appears in admin with "Unread" status
  3. Admin views message (status changes to "Read")
  4. Admin can mark as "Replied" or "Archived"

Categories

For organizing projects.

Fields

FieldTypeDescription
nameTextCategory name (required)
slugTextURL-friendly identifier
descriptionTextareaCategory description
colorTextDisplay color (hex)
orderNumberDisplay order

Media

File and image uploads.

Features

  • Automatic image optimization
  • Alt text for accessibility
  • Dimensions stored automatically
  • S3 storage integration
  • 10MB file size limit

Supported Types

  • Images: JPEG, PNG, GIF, WebP, SVG
  • Documents: PDF

Data Fetching

From Server Components

typescript
import { getPayload } from 'payload'
import config from '@payload-config'

export default async function Page() {
  const payload = await getPayload({ config })

  const { docs: projects } = await payload.find({
    collection: 'projects',
    where: { featured: { equals: true } },
    limit: 6,
  })

  return <ProjectsGrid projects={projects} />
}

Using Helper Functions

typescript
import { getProjects, getSkills, getExperience } from '@/lib/payload'

// In a Server Component
const [projects, skills, experience] = await Promise.all([
  getProjects({ featured: true, limit: 6 }),
  getSkills(),
  getExperience(),
])

Released under the MIT License.