This lecture covers the design and operation of beamlines, focusing on primary optics such as grating monochromators, spherical grating monochromators, and crystal monochromators. The instructor explains the principles behind these devices and their applications in synchrotrons and x-ray free-electron lasers.