On this page
Returns a list of the configured shards. listShards is only available for mongos instances. You can only issue listShards against the admin database.
The command takes the following form:
{ listShards: 1 }
The following example returns the list of shards:
db.getSiblingDB("admin").runCommand( { listShards: 1 } )