microsoft_teams_incoming_webhook_ruby 1.0.1 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bcd7a6c0a9d8ea6bd4b3976f79228ad531a1b197cda04651d61cb52eca8bc1d8
4
- data.tar.gz: edf51a1ce9e09fbe251ea346f404cea4590e963cd191fecb9894bff3eebc0178
3
+ metadata.gz: 5d6a6f3195a55056f01df70e9d34e8e5eb8295362ed9ec16f34a96b26491cbf1
4
+ data.tar.gz: 409e243fd39a19b1312892492885554da8a30762f31735f1162e0c48fe55f732
5
5
  SHA512:
6
- metadata.gz: 528b547f7cffc24ef983e8da8cb6d24ed199708c7f8886aea3fd9116c2eb45a2bb91edd496dd587cb0ea9d07b9867f43fa7dde35edff8034d92e80e27f84f759
7
- data.tar.gz: c01e7874cef3041c89bba79548d447b071cd606da990d0c1b4add89e79b6428fd98b27e259622d6971766f676efb677dd2615eed09e592f53d8c396dc3adf8c6
6
+ metadata.gz: 8f3223dc3cd9a7a459bd534fa609b63d3d9657da71fa8e6f4e114133977eea92618a24e885d234f57eec308b19ccfb90dfb74d420a118c0b93d105a773acca29
7
+ data.tar.gz: ff7ab10962d645c9d223934b3f1529600ebf75bb72510b260be8698dce3cdff0f858c2cdeb2e7217da3cd3f732019cc79aabacb897aafb06251008699f54726f
@@ -18,7 +18,7 @@ jobs:
18
18
  runs-on: ubuntu-latest
19
19
  strategy:
20
20
  matrix:
21
- ruby-version: [2.3, 2.4, 2.5, 2.6, 2.7, 3.0]
21
+ ruby-version: [2.6, 2.7, 3.0]
22
22
  env:
23
23
  CODECOV_TOKEN: ${{secrets.CODECOV_TOKEN}}
24
24
  steps:
data/.rubocop.yml CHANGED
@@ -8,6 +8,9 @@ AllCops:
8
8
  Gemspec/RequiredRubyVersion:
9
9
  Enabled: false
10
10
 
11
+ Style/OpenStructUse:
12
+ Enabled: false
13
+
11
14
  Style/Documentation:
12
15
  Enabled: false
13
16
 
data/LICENSE.txt CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) Pedro Furtado
3
+ Copyright (c) Kevin Chandler
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
data/README.md CHANGED
@@ -379,6 +379,113 @@ end
379
379
  message.send
380
380
  ```
381
381
 
382
+ ### Advanced
383
+
384
+ ```ruby
385
+ require 'microsoft_teams_incoming_webhook_ruby'
386
+
387
+ webhook_url = 'YOUR INCOMING WEBHOOK URL HERE'
388
+
389
+ message = MicrosoftTeamsIncomingWebhookRuby::Message.new do |m|
390
+ m.url = webhook_url
391
+ m.text = 'Advanced message'
392
+ m['@type'] = 'MessageCard'
393
+ m['@context'] = 'http://schema.org/extensions'
394
+ m.themeColor = '0076D7'
395
+ m.summary = 'Larry Bryant created a new task'
396
+
397
+ m.sections = [
398
+ {
399
+ 'activityTitle': 'Larry Bryant created a new task',
400
+ 'activitySubtitle': 'On Project Tango',
401
+ 'activityImage': 'https://teamsnodesample.azurewebsites.net/static/img/image5.png',
402
+ 'markdown': true,
403
+ 'facts': [
404
+ { 'name': 'Assigned to', 'value': 'Unassigned' },
405
+ { 'name': 'Due date', 'value': 'Mon May 01 2017 17:07:18 GMT-0700 (Pacific Daylight Time)' },
406
+ { 'name': 'Status', 'value': 'Not started' }
407
+ ]
408
+ }
409
+ ]
410
+
411
+ m.potentialAction = [
412
+ {
413
+ '@type': 'ActionCard',
414
+ 'name': 'Add a comment',
415
+ 'inputs': [
416
+ {
417
+ '@type': 'TextInput',
418
+ 'id': 'comment',
419
+ 'isMultiline': false,
420
+ 'title': 'Add a comment here for this task'
421
+ }
422
+ ],
423
+ 'actions': [
424
+ {
425
+ '@type': 'HttpPOST',
426
+ 'name': 'Add comment',
427
+ 'target': 'https://docs.microsoft.com/outlook/actionable-messages'
428
+ }
429
+ ]
430
+ },
431
+ {
432
+ '@type': 'ActionCard',
433
+ 'name': 'Set due date',
434
+ 'inputs': [
435
+ {
436
+ '@type': 'DateInput',
437
+ 'id': 'dueDate',
438
+ 'title': 'Enter a due date for this task'
439
+ }
440
+ ],
441
+ 'actions': [
442
+ {
443
+ '@type': 'HttpPOST',
444
+ 'name': 'Save',
445
+ 'target': 'https://docs.microsoft.com/outlook/actionable-messages'
446
+ }
447
+ ]
448
+ },
449
+ {
450
+ '@type': 'OpenUri',
451
+ 'name': 'Learn More',
452
+ 'targets': [
453
+ {
454
+ 'os': 'default',
455
+ 'uri': 'https://docs.microsoft.com/outlook/actionable-messages'
456
+ }
457
+ ]
458
+ },
459
+ {
460
+ '@type': 'ActionCard',
461
+ 'name': 'Change status',
462
+ 'inputs': [
463
+ {
464
+ '@type': 'MultichoiceInput',
465
+ 'id': 'list',
466
+ 'title': 'Select a status',
467
+ 'isMultiSelect': 'false',
468
+ 'choices': [
469
+ { 'display': 'In Progress', 'value': '1' },
470
+ { 'display': 'Active', 'value': '2' },
471
+ { 'display': 'Closed', 'value': '3' }
472
+ ]
473
+ }
474
+ ],
475
+ 'actions': [
476
+ {
477
+ '@type': 'HttpPOST',
478
+ 'name': 'Save',
479
+ 'target': 'https://docs.microsoft.com/outlook/actionable-messages'
480
+ }
481
+ ]
482
+ }
483
+ ]
484
+ end
485
+
486
+ message.send
487
+ ```
488
+
382
489
  ## Execute tests/specs
383
490
 
384
491
  To execute gem tests locally, use Docker with the commands below:
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module MicrosoftTeamsIncomingWebhookRuby
4
- VERSION = '1.0.1'
4
+ VERSION = '1.0.2'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: microsoft_teams_incoming_webhook_ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pedro Furtado
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-09-26 00:00:00.000000000 Z
11
+ date: 2022-05-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -128,7 +128,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
128
128
  - !ruby/object:Gem::Version
129
129
  version: '0'
130
130
  requirements: []
131
- rubygems_version: 3.2.22
131
+ rubygems_version: 3.3.7
132
132
  signing_key:
133
133
  specification_version: 4
134
134
  summary: Ruby gem for integration with Microsoft Teams Incoming Webhook