'\" t .\" Title: amqp-get .\" Author: The RabbitMQ Team <\m[blue]\fB\fR\m[]> .\" Generator: DocBook XSL Stylesheets vsnapshot .\" Date: 2024-05-04 .\" Manual: RabbitMQ C Client .\" Source: RabbitMQ C Client .\" Language: English .\" .TH "AMQP\-GET" "1" "2024\-05\-04" "RabbitMQ C Client" "RabbitMQ C Client" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" amqp-get \- Get a message from a queue on an AMQP server .SH "SYNOPSIS" .HP \w'\fBamqp\-get\fR\ 'u \fBamqp\-get\fR [\fIOPTION\fR...] {\-q\ \fIqueue\ name\fR} .SH "DESCRIPTION" .PP \fBamqp\-get\fR attempts to consume a single message from a queue on an AMQP server, and exits\&. Unless the queue was empty, the body of the resulting message is sent to standard output\&. .SH "OPTIONS" .PP \fB\-q\fR, \fB\-\-queue\fR=\fIqueue name\fR .RS 4 The name of the queue to consume messages from\&. .RE .SH "EXIT STATUS" .PP If the queue is not empty, and a message is successfully retrieved, the exit status is 0\&. If an error occurs, the exit status is 1\&. If the queue is found to be empty, the exit status is 2\&. .SH "EXAMPLES" .PP Get a message from the queue \(lqmyqueue\(rq, and display its body on standard output: .RS 4 .sp .if n \{\ .RS 4 .\} .nf $ \fBamqp\-get \-q myqueue\fR .fi .if n \{\ .RE .\} .RE .SH "SEE ALSO" .PP \fBlibrabbitmq-tools\fR(7) describes connection\-related options common to all the RabbitMQ C Client tools\&. .SH "AUTHOR" .PP \fBThe RabbitMQ Team <\fR\fB\m[blue]\fB\fR\m[]\fR\fB>\fR