c8y(1)
π¦ c8y(1) β the c8y manual, bestie edition π
okay so this is the manual page for c8y, and more specifically for the c8y events list command. it's a whole vibe, it's giving "I read the docs so you don't have to" energy. buckle up π
β¨ NAME β¨
c8y-events-list β get event collection. that's it. that's the whole name. iconic brevity π
β¨ SYNOPSIS β¨
c8y events list [flags]
that's your whole incantation. c8y events list, plus whatever flags you're feeling πΈ
β¨ DESCRIPTION β¨
bestie, this command grabs you a collection of events, filtered however you like via filter parameters. think of it as the events shelf at the library and you're the main character with a very specific request β¨
β¨ OPTIONS β¨
here's your flag menu, no cap. every single one, and what it does π
--createdFrom=""β start date (or date and time) of when the event was created. this one's set by the platform during creation, so don't come for it π«Ά--createdTo=""β end date (or date and time) of when the event was created. also platform-set, also not your business to write πΈ--dateFrom=""β start date or date and time of when the event actually occurred. yes, different from created. yes, that matters π--dateTo=""β end date or date and time of when the event occurred β--device=[]β device ID. it also accepts pipeline input, so you can pipe it in like a boss π₯--fragmentType=""β fragment name from the event π¦--fragmentValue=""β lets you filter events by the fragment's value, but only when you provide it together withfragmentType. it's a package deal, they don't come separately π-h,--help[=false]β help forlist. your little safety net π§--lastUpdatedFrom=""β start date or date and time of the last update made π--lastUpdatedTo=""β end date or date and time of the last update made π--revert[=false]β returns the newest events instead of the oldest. must be used withdateFromanddateToparameters β don't try it solo, it will not slay π--type=""β event type. your filter's main character moment π--withSourceAssets[=false]β when set totrue, events for related source assets get included in the request too. when this parameter is provided a source must be specified β οΈ--withSourceDevices[=false]β when set totrue, events for related source devices get included in the request too. same rule: when this parameter is provided a source must be specified β οΈ
π OPTIONS INHERITED FROM PARENT COMMANDS π
these bad boys you didn't ask for but you get anyway. they're the family heirlooms π
--abortOnErrors=10β aborts the batch when it reaches the specified number of errors π--allowEmptyPipe[=false]β don't fail when the piped input (stdin) is empty. empty is valid, okay π«Ά--cache[=false]β enable cached responses β--cacheBodyPaths=[]β limits hashing to selected paths in the json body for the cache. empty means all values πΈ--cacheTTL="60s"β cache time-to-live as a duration, i.e.60s,2mβ³-c,--compact[=false]β compact instead of pretty-printed output when using json output. pretty print is the default if output is the terminal β¨--confirm[=false]β prompt for confirmation π--confirmText=""β custom confirmation text, for when you wanna ask in your own words π--currentPage=0β the current page which should be returned π--customQueryParam=[]β add custom URL query parameters, i.e.--customQueryParam 'withCustomOption=true,myOtherOption=myvalue'π₯--debug[=false]β set very verbose log messages. it will NOT shut up, and that's the point π--delay="0ms"β delay after each request, i.e.5ms,1.2sβ±οΈ--delayBefore="0ms"β delay before each request, i.e.5ms,1.2sβ±οΈ--dry[=false]β dry run. don't send any data to the server. all the vibes, none of the consequences π§--dryFormat="markdown"β dry run output format, i.e.json,dump,markdownorcurlπ--examples[=false]β show examples for the current command π--filter=[]β apply a client side filter to the response before returning it to you π¦--flatten[=false]β flatten json output by replacing nested json properties with properties where their names are represented by dot notation πͺ-f,--force[=false]β do not prompt for confirmation. ignored when using--confirmβ pick a lane bestie π-H,--header=[]β custom headers, i.e.--header "Accept: value, AnotherHeader: myvalue"π--includeAll[=false]β include all results by iterating through each page. all of them. every last one π-k,--insecure[=false]β allow insecure server connections when using SSL β οΈ-l,--logMessage=""β add a custom message to the activity log βοΈ--maxJobs=0β maximum number of jobs.0= unlimited (use with caution!) π--noAccept[=false]β ignore the Accept header; this removes the Accept header from requests, however PUT and POST requests will only see the effect π«--noCache[=false]β force disabling of cached responses (overwrites the cache setting) π«-M,--noColor[=false]β don't use colors when displaying log entries on the console π¨--noLog[=false]β disables the activity log for the current command π--noProgress[=false]β disable progress bars π«--noProxy[=false]β ignore the proxy settings π-n,--nullInput[=false]β don't read the input (stdin). useful if using in shellfor/whileloops π-o,--output="table"β output format, i.e.table,json,csv,csvheaderπ--outputFile=""β save JSON output to file (after select/view) πΎ--outputFileRaw=""β save raw response to file (before select/view) πΎ--outputTemplate=""β jsonnet template to apply to the output πͺ-p,--pageSize=5β maximum results per page π--progress[=false]β show progress bar. this will also disable any other verbose output π--proxy=""β proxy setting, i.e.http://10.0.0.1:8080π-r,--raw[=false]β show raw response. this mode will forceoutput=jsonandview=offπ--retries=3β max number of attempts when a failed http call is encountered π--select=[]β comma separated list of properties to return. wildcards and globstar accepted, i.e.--select 'id,name,type,**.serialNumber'β¨--session=""β session configuration π--sessionMode=""β override the default session mode for a single command, which would normally be disabled π¦-P,--sessionPassword=""β override session password π-U,--sessionUsername=""β override session username, i.e.peterort1234/peter(with tenant) π€--silentExit[=false]β silent status codes do not affect the exit code π€«--silentStatusCodes=""β status codes which will not print out an error message π--timeout="600s"β request timeout duration, i.e.60s,2mβ³--totalPages=0β total number of pages to get π-v,--verbose[=false]β verbose logging π£οΈ--view="auto"β use views when displaying data on the terminal. disable using--view offπ--withError[=false]β errors will be printed on stdout instead of stderr π¨--withTotalElements[=false]β request Cumulocity to include the total elements in the response statistics under.statistics.totalElements(introduced in10.13) π-t,--withTotalPages[=false]β request Cumulocity to include the total pages in the response statistics under.statistics.totalPagesπ--workers=1β number of workers π·
πΈ EXAMPLE πΈ
okay these are the actually-useful ones, pay attention bestie π
$ c8y events list --type my_CustomType --dateFrom "-10d"
Get events with type 'my_CustomType' that were created in the last 10 days
that's you getting events of type my_CustomType created in the last 10 days. slay β¨
$ c8y events list --device 12345
Get events from a device
and that's you getting events from a device. two lines, both iconic π«Ά
π SEE ALSO π
c8y-events(1)β the parent, the origin story, the mothership π
and that's the page!! this lil manual is from Jan 1980 (yes really, that's the date on the tin, we don't question it π) and it's part of the c8y(1) manual β so go forth, filter your events, and remember: --fragmentValue never travels alone π§ββοΈπ
π¦ where this page comes from
- nixpkgs unstable: go-c8y-cli 2.56.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms