JsonSerializationException when using Discord Messages supportError

Hey guys, I am getting this message in console when enhanced ban system is sending through discord messages. any way I can fix this error?

Failed to call hook 'API_SendFancyMessage' on plugin 'DiscordMessages v2.1.3' (JsonSerializationException: Cannot deserialize the current JSON array (e.g. [1,2,3]) into type 'Oxide.Plugins.DiscordMessages+EmbedBuilder' because the type requires a JSON object (e.g. {"name":"value"}) to deserialize correctly. To fix this error either change the JSON to a JSON object (e.g. {"name":"value"}) or change the deserialized type to an array or a type that implements a collection interface (e.g. ICollection, IList) like List that can be deserialized from a JSON array. JsonArrayAttribute can also be added to the type to force it to deserialize from a JSON array.

No they are not

Merged post

I checked both plugins 
Did u try editing the hardcoded embed builder in the plugin? Looks like that's the issue.

No the only thing I have changed is the Command because everyone uses the command /ban.

If the all the plugins could have a configurable command option then we would not have to edit the plugin in the first place 

This Function is broken.... No fix since 11 Months now.

Merged post

I found the issue. Always happy to doing others Job...

The Call for API_SendFancyMessage is implememted wrong. There are 2 overload Functions for that and the one this Plugin is using can't work. To use the correct one just add the color in the Paramater set aswell.

 

Replace:

DiscordMessages?.Call("API_SendFancyMessage", Discord_Webhook, "Player Ban", json);
 
With:
DiscordMessages?.Call("API_SendFancyMessage", Discord_Webhook, "Player Ban", 3329330, json);
 
 
Do that with all calls in this Plugin and it works again.
5fa36167a1cbb.png OldSpice

Replace:

DiscordMessages?.Call("API_SendFancyMessage", Discord_Webhook, "Player Ban", json);
 
With:
DiscordMessages?.Call("API_SendFancyMessage", Discord_Webhook, "Player Ban", 3329330, json);
 
 
Do that with all calls in this Plugin and it works again.
Patches are enable for this plugin. If you wish, you can submit a fixed version via the green "patch" button on the plugin page. Then this fix can be applied to the official version instead of people having to search around for unofficial versions or scour threads to find which lines to change.
Thanks for the suggestion. Since i just did a "Hotfix" here with a static color i didn't wanted to. Maybe adding a config option aswell.