NNTP Reference
Network News Transport Protocol
NNTP Standard RFC 977, Brian Kantor, Phil Lapsely, Februrary 1986
NNTP Extensions RFC 2980, Stan Barber, October 2000
NNTP uses TCP port 119.

Protocol Model
The NNTP server specified for this protocol uses a stream connection (such as TCP) and SMTP-like commands and responses. It is designed to accept connections from hosts, and to provide a simple interface to the news database.
Command Summary
Commands consist of a command word, which in some cases may be followed by a parameter. Commands with parameters must separate the parameters from each other and from the command by one or more space or tab characters. Command lines must be complete with all required parameters, and may not contain more than one command.

Commands and command parameters are not case sensitive. That is, a command or parameter word may be upper case, lower case, or any mixture of upper and lower case.

Each command line must be terminated by a CR-LF (Carriage Return - Line Feed) pair. Command lines shall not exceed 512 characters in length, counting all characters including spaces, separators, punctuation, and the trailing CR-LF (thus there are 510 characters maximum allowed for the command and its parameters). There is no provision for continuation command lines.
Command Syntax Error Codes
Description
ARTICLE ARTICLE <message-id>
HEAD <message-id>
BODY <message-id>
STAT <message-id>
S: 220, 221, 222, 223
F: 412, 420, 423, 430
  This form of the ARTICLE command is distinguished by having the message-id enclosed with angle-brackets(< and >).

In the ARTICLE form, this returns the header, a blank line, then the body (text) of the specified article. The HEAD, BODY, and STAT commands return only the header, the body, or the status for the selected message id.

 
ARTICLE ARTICLE nnn
HEAD nnn
BODY nnn
STAT nnn
S: 220, 221, 222, 223
F: 412, 420, 423, 430
  This form of the ARTICLE command is distinguished by having a numeric message number which identifes an artical in the currently selected newsgroup.

In the ARTICLE form, this returns the header, a blank line, then the body (text) of the specified article. The HEAD, BODY, and STAT commands return only the header, the body, or the status for the selected message id.

 
HELP HELP  
     
IHAVE IHAVE <message-id>  
     
LAST LAST  
     
LIST LIST  
     
NEWSGROUPS NEWSGROUPS date time [GMT] [<distributions>]  
     
NEWNEWS NEWNEWS newsgroups date time [GMT] [<distributions>]  
     
NEXT NEXT  
     
POST POST  
     
QUIT QUIT  
     
SLAVE SLAVE  
     
     
     
CHECK CHECKmessage-id  
  CHECK is used by a peer to discover if the article with the specified message-id should be sent to the server using the TAKETHIS command.
MODE STREAM MODE STREAM  
  Ask the server to enter streaming mode
TAKETHIS TAKETHISmessage-id  
  Set a recipient of the mail data; multiple recipients are specified by multiple uses of this command.
XREPLIC XREPLIC ggg:nnn[,ggg:nnn...]  
   
  LIST ACTIVE [wildmat]  
   
  LIST ACTIVE.TIMES  
 
  LIST DISTRIBUTIONS  
 
  LIST DISTRIB.PATS  
 
  LIST NEWSGROUPS [wildmat]  
 
  LIST OVERVIEW.FMT  
 
  LIST SUBSCRIPTIONS  
 
  LISTGROUP [ggg]  
 
  MODE READER  
 
  XGTITLE [wildmat]  
   
  XHDR header [range|<messaage-id>]  
   
  XINDEX ggg  
   
  XOVER [range]  
   
  XPAT header range|<messaage-id> pat [pat...]  
   
  XPATH <messaage-id>  
   
  XROVER [range]  
   
  XTHREAD [DBINIT|THREAD]  
   
  AUTHINFO USER username  
   
  AUTHINFO PASS password  
   
  AUTHINFO SIMPLE  
   
  AUTHINFO GENERIC authenticator arguments...  
   
  DATE