Edward Snowden, the National Security Agency contractor who leaked a trove of secret documents in 2013, has written a memoir expected to come out Sept. 17, his publisher said Thursday.

The publisher, Metropolitan Books, an imprint of Macmillan Publishers, is releasing the book, “Permanent Record,” in the United States, though it will be published in more than 20 countries, including Britain and Germany, on the same date. A Metropolitan spokeswoman declined to say how much Mr. Snowden was paid.

“Permanent Record” discusses how Mr. Snowden helped create a system of mass surveillance the N.S.A. used to collect information on hundreds of millions of United States citizens and others, as well as the “crisis of conscience” that led him to rebuke the system he helped create, according to a statement from the publisher. Mr. Snowden consulted with several people on the structure of the book but wrote it himself, the spokeswoman said.

In a video posted to his Twitter account Thursday morning, Mr. Snowden expressed regret for his role at the N.S.A. “Everything that we do now lasts forever, not because we’d want to remember, but because we’re no longer allowed to forget,” he said. “Helping to create that system is my greatest regret.” The video also notes that the book’s Sept. 17 release date is Constitution Day, which recognizes the date the United States’ foundational document was signed in 1787.