Skip to content

Commit

Permalink
Added the 'graph teams channel message get' command solving #589
Browse files Browse the repository at this point in the history
  • Loading branch information
arjenbloemsma authored and waldekmastykarz committed Nov 11, 2018
1 parent 6a36e6b commit a42c360
Show file tree
Hide file tree
Showing 5 changed files with 537 additions and 0 deletions.
41 changes: 41 additions & 0 deletions docs/manual/docs/cmd/graph/teams/teams-channel-message-get.md
@@ -0,0 +1,41 @@
# graph teams channel message get

Retrieves a message from a channel in a Microsoft Teams team

## Usage

```sh
graph teams channel message get [options]
```

## Options

Option|Description
------|-----------
`--help`|output usage information
`-i, --teamId <teamId>`|The ID of the team where the channel is located
`-c, --channelId <channelId>`|The ID of the channel that contains the message
`-m, --messageId <messageId>`|The ID of the message to retrieve
`-o, --output [output]`|Output type. `json|text`. Default `text`
`--verbose`|Runs command with verbose logging
`--debug`|Runs command with debug logging

!!! important
Before using this command, log in to the Microsoft Graph, using the [graph login](../login.md) command.

## Remarks

!!! attention
This command is based on an API that is currently in preview and is subject to change once the API reached general availability.

To retrieve a message from a Microsoft Teams channel, you have to first log in to the Microsoft Graph using the [graph login](../login.md) command, eg. `graph login`.

You can only retrieve a message from a Microsoft Teams team if you are a member of that team.

## Examples

Retrieve the specified message from a channel of the Microsoft Teams team

```sh
graph teams channel message get --teamId 5f5d7b71-1161-44d8-bcc1-3da710eb4171 --channelId 19:88f7e66a8dfe42be92db19505ae912a8@thread.skype --messageId 1540747442203
```
1 change: 1 addition & 0 deletions docs/manual/mkdocs.yml
Expand Up @@ -209,6 +209,7 @@ nav:
- teams:
- teams list: 'cmd/graph/teams/teams-list.md'
- teams channel add: 'cmd/graph/teams/teams-channel-add.md'
- teams channel message get: 'cmd/graph/teams/teams-channel-message-get.md'
- user:
- user get: 'cmd/graph/user/user-get.md'
- user list: 'cmd/graph/user/user-list.md'
Expand Down
1 change: 1 addition & 0 deletions src/o365/graph/commands.ts
Expand Up @@ -25,6 +25,7 @@ export default {
STATUS: `${prefix} status`,
TEAMS_LIST: `${prefix} teams list`,
TEAMS_CHANNEL_ADD: `${prefix} teams channel add`,
TEAMS_CHANNEL_MESSAGE_GET: `${prefix} teams channel message get`,
USER_GET: `${prefix} user get`,
USER_LIST: `${prefix} user list`,
USER_SENDMAIL: `${prefix} user sendmail`,
Expand Down

0 comments on commit a42c360

Please sign in to comment.