Checkpoint
Checkpoint database P1.
An example
1 of the 178 statements we compiled against the sample database use Checkpoint. This is the one with the shortest program; the rows that use Checkpoint are highlighted.
PRAGMA wal_checkpoint
Open it in the EXPLAIN visualizer →
Also in this program: Expire, Goto, Halt, Init, ResultRow.
What the SQLite documentation says
Checkpoint database P1. This is a no-op if P1 is not currently in WAL mode. Parameter P2 is one of SQLITE_CHECKPOINT_PASSIVE, FULL, RESTART, or TRUNCATE. Write 1 or 0 into mem[P3] if the checkpoint returns SQLITE_BUSY or not, respectively. Write the number of pages in the WAL after the checkpoint into mem[P3+1] and the number of pages in the WAL that have been checkpointed after the checkpoint completes into mem[P3+2]. However on an error, mem[P3+1] and mem[P3+2] are initialized to -1.
From sqlite.org's list of opcodes for SQLite 3.54.1, in the public domain. Opcodes are not a stable interface and change between releases.