summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--npc/functions/util.txt9
1 files changed, 9 insertions, 0 deletions
diff --git a/npc/functions/util.txt b/npc/functions/util.txt
index c23352147..75f1faf64 100644
--- a/npc/functions/util.txt
+++ b/npc/functions/util.txt
@@ -1061,3 +1061,12 @@ function script json_encode {
}
+// api_send( code, data )
+// sends to API
+function script api_send {
+ .@cde=getarg(0);
+ .@fm$=getarg(1);
+ query_sql("INSERT INTO `api_export` (`type`, `data`) VALUES ('"+.@cde+"', \""+.@fm$+"\")");
+ return;
+}
+