Initial commit: sap-legacy-webhook-emulator
Reconstruye el Webhook Messenger nativo de SAP B1 (FP2605) para clientes que aun no estan en esa version: captura eventos via SBO_SP_PostTransactionNotice, provisiona UserTables OEVC/EVC1/OEVN/EVN1 y despacha CloudEvents al mismo endpoint que el messenger real. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
commit
e1c8ee9015
42 files changed
+4042
No files matched your search
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"_comment": "POST /U_EVC1 — filtro para capturar Items (ObjectType=4) actualizados, para la suscripción TEST_LOCAL. Equivalente a: npx tsx scripts/manage-subscriptions.ts filter:add TEST_LOCAL Items U 4. El 'Code' es un UUID cualquiera (debe ser único, ver docs/DISENO.md decisión 5) — reemplazarlo si se postea manualmente.",
|
||||
"Code": "<uuid-nuevo>",
|
||||
"Name": "<mismo-uuid-que-Code>",
|
||||
"U_WebhookID": "TEST_LOCAL",
|
||||
"U_BizObject": "Items",
|
||||
"U_TransType": "U",
|
||||
"U_ObjectType": "4"
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"_comment": "POST /U_OEVC — suscripción de prueba, apunta al listener HTTP local levantado para esta prueba (scripts/_tmp-fake-webhook-receiver.ts). Equivalente a: npx tsx scripts/manage-subscriptions.ts subscription:add TEST_LOCAL http://127.0.0.1:4100/webhooks/sap",
|
||||
"Code": "TEST_LOCAL",
|
||||
"Name": "TEST_LOCAL",
|
||||
"U_WebhookURL": "http://127.0.0.1:4100/webhooks/sap",
|
||||
"U_AuthType": "N",
|
||||
"U_AuthCred": null,
|
||||
"U_State": "A",
|
||||
"U_WorkMode": "S"
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
{
|
||||
"table": {
|
||||
"TableName": "EVC1",
|
||||
"TableDescription": "Webhook Subscription Filter",
|
||||
"TableType": "bott_NoObject"
|
||||
},
|
||||
"fields": [
|
||||
{
|
||||
"TableName": "@EVC1",
|
||||
"Name": "WebhookID",
|
||||
"Description": "WebhookID",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 40,
|
||||
"EditSize": 40
|
||||
},
|
||||
{
|
||||
"TableName": "@EVC1",
|
||||
"Name": "BizObject",
|
||||
"Description": "BizObject",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 64,
|
||||
"EditSize": 64
|
||||
},
|
||||
{
|
||||
"TableName": "@EVC1",
|
||||
"Name": "TransType",
|
||||
"Description": "TransType",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 1,
|
||||
"EditSize": 1
|
||||
},
|
||||
{
|
||||
"TableName": "@EVC1",
|
||||
"Name": "ObjectType",
|
||||
"Description": "ObjectType",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 30,
|
||||
"EditSize": 30
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,63 @@
|
||||
{
|
||||
"table": {
|
||||
"TableName": "EVN1",
|
||||
"TableDescription": "Webhook Event Delivery",
|
||||
"TableType": "bott_NoObject"
|
||||
},
|
||||
"fields": [
|
||||
{
|
||||
"TableName": "@EVN1",
|
||||
"Name": "EventID",
|
||||
"Description": "EventID",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 40,
|
||||
"EditSize": 40
|
||||
},
|
||||
{
|
||||
"TableName": "@EVN1",
|
||||
"Name": "WebhookID",
|
||||
"Description": "WebhookID",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 40,
|
||||
"EditSize": 40
|
||||
},
|
||||
{
|
||||
"TableName": "@EVN1",
|
||||
"Name": "Status",
|
||||
"Description": "Status",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 1,
|
||||
"EditSize": 1
|
||||
},
|
||||
{
|
||||
"TableName": "@EVN1",
|
||||
"Name": "Retry",
|
||||
"Description": "Retry",
|
||||
"Type": "db_Numeric",
|
||||
"Size": 6,
|
||||
"EditSize": 6
|
||||
},
|
||||
{
|
||||
"TableName": "@EVN1",
|
||||
"Name": "ReturnCode",
|
||||
"Description": "ReturnCode",
|
||||
"Type": "db_Numeric",
|
||||
"Size": 9,
|
||||
"EditSize": 9
|
||||
},
|
||||
{
|
||||
"TableName": "@EVN1",
|
||||
"Name": "LastSentDT",
|
||||
"Description": "LastSentDT",
|
||||
"Type": "db_Date"
|
||||
},
|
||||
{
|
||||
"TableName": "@EVN1",
|
||||
"Name": "LastSentTM",
|
||||
"Description": "LastSentTM",
|
||||
"Type": "db_Numeric",
|
||||
"Size": 9,
|
||||
"EditSize": 9
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,87 @@
|
||||
{
|
||||
"table": {
|
||||
"TableName": "OEVC",
|
||||
"TableDescription": "Webhook Subscription",
|
||||
"TableType": "bott_NoObject"
|
||||
},
|
||||
"fields": [
|
||||
{
|
||||
"TableName": "@OEVC",
|
||||
"Name": "WebhookURL",
|
||||
"Description": "WebhookURL",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 254,
|
||||
"EditSize": 254
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVC",
|
||||
"Name": "AuthType",
|
||||
"Description": "AuthType",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 1,
|
||||
"EditSize": 1
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVC",
|
||||
"Name": "AuthCred",
|
||||
"Description": "AuthCred",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 254,
|
||||
"EditSize": 254
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVC",
|
||||
"Name": "Handshake",
|
||||
"Description": "Handshake",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 1,
|
||||
"EditSize": 1
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVC",
|
||||
"Name": "VerifyCert",
|
||||
"Description": "VerifyCert",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 1,
|
||||
"EditSize": 1
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVC",
|
||||
"Name": "State",
|
||||
"Description": "State",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 1,
|
||||
"EditSize": 1
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVC",
|
||||
"Name": "WorkMode",
|
||||
"Description": "WorkMode",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 1,
|
||||
"EditSize": 1
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVC",
|
||||
"Name": "LastSentDT",
|
||||
"Description": "LastSentDT",
|
||||
"Type": "db_Date"
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVC",
|
||||
"Name": "LastSentTM",
|
||||
"Description": "LastSentTM",
|
||||
"Type": "db_Numeric",
|
||||
"Size": 9,
|
||||
"EditSize": 9
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVC",
|
||||
"Name": "LastErrMsg",
|
||||
"Description": "LastErrMsg",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 254,
|
||||
"EditSize": 254
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,81 @@
|
||||
{
|
||||
"table": {
|
||||
"TableName": "OEVN",
|
||||
"TableDescription": "Webhook Event",
|
||||
"TableType": "bott_NoObject"
|
||||
},
|
||||
"fields": [
|
||||
{
|
||||
"TableName": "@OEVN",
|
||||
"Name": "SourceDB",
|
||||
"Description": "SourceDB",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 100,
|
||||
"EditSize": 100
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVN",
|
||||
"Name": "Status",
|
||||
"Description": "Status",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 1,
|
||||
"EditSize": 1
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVN",
|
||||
"Name": "ObjectType",
|
||||
"Description": "ObjectType",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 30,
|
||||
"EditSize": 30
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVN",
|
||||
"Name": "TransType",
|
||||
"Description": "TransType",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 1,
|
||||
"EditSize": 1
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVN",
|
||||
"Name": "FieldsInKe",
|
||||
"Description": "FieldsInKe",
|
||||
"Type": "db_Numeric",
|
||||
"Size": 6,
|
||||
"EditSize": 6
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVN",
|
||||
"Name": "FieldNames",
|
||||
"Description": "FieldNames",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 254,
|
||||
"EditSize": 254
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVN",
|
||||
"Name": "FieldValue",
|
||||
"Description": "FieldValue",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 254,
|
||||
"EditSize": 254
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVN",
|
||||
"Name": "ReplayStat",
|
||||
"Description": "ReplayStat",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 1,
|
||||
"EditSize": 1
|
||||
},
|
||||
{
|
||||
"TableName": "@OEVN",
|
||||
"Name": "UserID",
|
||||
"Description": "UserID",
|
||||
"Type": "db_Alpha",
|
||||
"Size": 25,
|
||||
"EditSize": 25
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in new issue
Block a user