Skip to content

Commit

Permalink
Merge pull request #13 from splunk-soar-connectors/kzuchowska/fix-json
Browse files Browse the repository at this point in the history
Fix discord app
  • Loading branch information
kzuchowska-splunk authored Feb 10, 2025
2 parents 89ca92a + 2678878 commit 71b83df
Show file tree
Hide file tree
Showing 28 changed files with 386 additions and 335 deletions.
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
repos:
- repo: https://github.com/phantomcyber/dev-cicd-tools
rev: v1.16
rev: v1.26
hooks:
- id: org-hook
- id: package-app-dependencies
- repo: https://github.com/Yelp/detect-secrets
rev: v1.4.0
rev: v1.5.0
hooks:
- id: detect-secrets
args: ['--no-verify']
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -198,4 +198,4 @@
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
limitations under the License.
301 changes: 174 additions & 127 deletions README.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion __init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# File: __init__.py
#
# Copyright (c) 2024 Splunk Inc.
# Copyright (c) 2024-2025 Splunk Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand Down
89 changes: 47 additions & 42 deletions discord.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"appid": "0e4f8ac8-af3d-4fbd-802f-fd06607fe0b9",
"name": "Discord",
"description": "Integrate with Discord to post messages and attachments to channels",
"description": "Integrate with Discord to post messages and manage users in guilds",
"contributors": [
{
"name": "Kacper Czernik"
Expand All @@ -16,14 +16,15 @@
"logo_dark": "discord_dark.svg",
"product_name": "Discord",
"python_version": "3",
"fips_compliant": true,
"product_version_regex": ".*",
"publisher": "Splunk",
"license": "Copyright (c) 2024 Splunk Inc.",
"app_version": "1.0.1",
"license": "Copyright (c) 2025 Splunk Inc.",
"app_version": "1.0.2",
"utctime_updated": "2024-08-12T12:06:21.058775Z",
"package_name": "phantom",
"package_name": "phantom_discord",
"main_module": "discord_connector.py",
"min_phantom_version": "6.2.2.134",
"min_phantom_version": "6.3.0",
"app_wizard_version": "1.0.0",
"configuration": {
"token": {
Expand Down Expand Up @@ -416,7 +417,7 @@
]
},
{
"data_path": "action_result.data.*.message origin.channel id",
"data_path": "action_result.data.*.message_origin.channel_id",
"data_type": "numeric",
"contains": [
"discord channel id"
Expand All @@ -425,7 +426,7 @@
"column_order": 0
},
{
"data_path": "action_result.data.*.message origin.channel name",
"data_path": "action_result.data.*.message_origin.channel_name",
"data_type": "string",
"contains": [
"discord channel name"
Expand All @@ -434,7 +435,7 @@
"column_order": 1
},
{
"data_path": "action_result.data.*.message data.created at",
"data_path": "action_result.data.*.message_data.created_at",
"data_type": "numeric",
"contains": [
"date"
Expand All @@ -443,7 +444,7 @@
"column_order": 2
},
{
"data_path": "action_result.data.*.message data.edited at",
"data_path": "action_result.data.*.message_data.edited_at",
"data_type": "numeric",
"contains": [
"date"
Expand All @@ -452,7 +453,7 @@
"column_order": 3
},
{
"data_path": "action_result.data.*.author data.author id",
"data_path": "action_result.data.*.author_data.author_id",
"data_type": "numeric",
"contains": [
"author id",
Expand All @@ -462,7 +463,7 @@
"column_order": 4
},
{
"data_path": "action_result.data.*.author data.author name",
"data_path": "action_result.data.*.author_data.author_name",
"data_type": "string",
"contains": [
"author name"
Expand Down Expand Up @@ -498,7 +499,7 @@
"column_order": 8
},
{
"data_path": "action_result.data.*.jump url",
"data_path": "action_result.data.*.jump_url",
"data_type": "string",
"contains": [
"url"
Expand Down Expand Up @@ -581,7 +582,7 @@
"contains": [
"discord channel id"
],
"column_name": "channel_id",
"column_name": "channel id",
"column_order": 0
},
{
Expand All @@ -590,7 +591,7 @@
"contains": [
"discord message id"
],
"column_name": "message_id",
"column_name": "message id",
"column_order": 1
},
{
Expand Down Expand Up @@ -626,7 +627,7 @@
"read_only": true,
"parameters": {
"channel_id": {
"description": "discord channel id",
"description": "The ID of a channel to fetch message history from",
"data_type": "string",
"required": true,
"primary": true,
Expand All @@ -639,7 +640,7 @@
"name": "channel_id"
},
"fetching_start_date": {
"description": "fetching start date (UTC): %Y-%m-%d %H:%M:%S",
"description": "Fetching start date (UTC): %Y-%m-%d %H:%M:%S",
"data_type": "string",
"required": false,
"primary": false,
Expand All @@ -654,7 +655,7 @@
"param_name": "fetching_start_date"
},
"fetching_end_date": {
"description": "fetching end date (UTC): %Y-%m-%d %H:%M:%S",
"description": "Fetching end date (UTC): %Y-%m-%d %H:%M:%S",
"data_type": "string",
"required": false,
"primary": false,
Expand All @@ -669,7 +670,7 @@
"param_name": "fetching_end_date"
},
"limit": {
"description": "messages limit",
"description": "Limit of messages",
"data_type": "numeric",
"required": false,
"primary": false,
Expand All @@ -682,7 +683,7 @@
"name": "limit"
},
"oldest_first": {
"description": "oldest first",
"description": "Set to true for having oldest messages first",
"data_type": "boolean",
"required": false,
"primary": false,
Expand All @@ -691,7 +692,7 @@
false,
true
],
"default": "",
"default": false,
"order": 4,
"name": "oldest first"
}
Expand All @@ -703,7 +704,7 @@
"contains": [
"discord channel id"
],
"column_name": "channel_id",
"column_name": "channel id",
"column_order": 0
},
{
Expand All @@ -712,7 +713,7 @@
"contains": [
"date"
],
"column_name": "fetching_start_date",
"column_name": "fetching start date",
"column_order": 1
},
{
Expand All @@ -721,7 +722,7 @@
"contains": [
"date"
],
"column_name": "fetching_end_date",
"column_name": "fetching end date",
"column_order": 2
},
{
Expand All @@ -740,16 +741,16 @@
"data_path": "action_result.data.*.message id",
"data_type": "string",
"column_name": "message ID",
"column_order": 0,
"column_order": 3,
"contains": [
"discord message id"
]
},
{
"data_path": "action_result.data.*.author id",
"data_path": "action_result.data.*.author_id",
"data_type": "string",
"column_name": "Author ID",
"column_order": 3,
"column_order": 4,
"contains": [
"discord user id"
]
Expand All @@ -758,7 +759,7 @@
"data_path": "action_result.data.*.created at",
"data_type": "string",
"column_name": "Creation date",
"column_order": 4,
"column_order": 5,
"contains": [
"date"
]
Expand All @@ -767,7 +768,7 @@
"data_path": "action_result.data.*.embeds_attachments",
"data_type": "string",
"column_name": "Embeds/Attachments",
"column_order": 5,
"column_order": 6,
"contains": [
"discord message embeds_attachments"
]
Expand All @@ -776,7 +777,7 @@
"data_path": "action_result.data.*.content",
"data_type": "string",
"column_name": "content",
"column_order": 6,
"column_order": 7,
"contains": [
"message content"
]
Expand All @@ -785,7 +786,7 @@
"data_path": "action_result.status",
"data_type": "string",
"column_name": "status",
"column_order": 7
"column_order": 8
},
{
"data_path": "action_result.message",
Expand Down Expand Up @@ -834,7 +835,7 @@
"contains": [
"discord user id"
],
"column_name": "user_id",
"column_name": "user id",
"column_order": 0
},
{
Expand Down Expand Up @@ -915,43 +916,47 @@
"wheel": [
{
"module": "aiohappyeyeballs",
"input_file": "wheels/py3/aiohappyeyeballs-2.4.0-py3-none-any.whl"
"input_file": "wheels/py3/aiohappyeyeballs-2.4.4-py3-none-any.whl"
},
{
"module": "aiohttp",
"input_file": "wheels/py39/aiohttp-3.10.5-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl"
"input_file": "wheels/py39/aiohttp-3.11.11-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl"
},
{
"module": "aiosignal",
"input_file": "wheels/py3/aiosignal-1.3.1-py3-none-any.whl"
"input_file": "wheels/shared/aiosignal-1.3.2-py2.py3-none-any.whl"
},
{
"module": "async_timeout",
"input_file": "wheels/py3/async_timeout-4.0.3-py3-none-any.whl"
"input_file": "wheels/py3/async_timeout-5.0.1-py3-none-any.whl"
},
{
"module": "attrs",
"input_file": "wheels/py3/attrs-24.2.0-py3-none-any.whl"
"input_file": "wheels/py3/attrs-25.1.0-py3-none-any.whl"
},
{
"module": "discord.py",
"input_file": "wheels/py3/discord.py-2.4.0-py3-none-any.whl"
},
{
"module": "frozenlist",
"input_file": "wheels/py39/frozenlist-1.4.1-cp39-cp39-manylinux1_x86_64.manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_5_x86_64.whl"
"input_file": "wheels/py39/frozenlist-1.5.0-cp39-cp39-manylinux1_x86_64.manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_5_x86_64.manylinux_2_28_x86_64.whl"
},
{
"module": "idna",
"input_file": "wheels/py3/idna-3.7-py3-none-any.whl"
"module": "multidict",
"input_file": "wheels/py39/multidict-6.1.0-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl"
},
{
"module": "multidict",
"input_file": "wheels/py39/multidict-6.0.5-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl"
"module": "propcache",
"input_file": "wheels/py39/propcache-0.2.1-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl"
},
{
"module": "typing_extensions",
"input_file": "wheels/py3/typing_extensions-4.12.2-py3-none-any.whl"
},
{
"module": "yarl",
"input_file": "wheels/py39/yarl-1.9.4-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl"
"input_file": "wheels/py39/yarl-1.18.3-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl"
}
]
}
Expand Down
2 changes: 1 addition & 1 deletion discord_artifact.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# File: discord_artifact.py
#
# Copyright (c) 2024 Splunk Inc.
# Copyright (c) 2024-2025 Splunk Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand Down
Loading

0 comments on commit 71b83df

Please sign in to comment.