diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..23c61da --- /dev/null +++ b/.gitignore @@ -0,0 +1,23 @@ +# 忽略日志文件 +log/ +logs/ +*.log + +# 忽略编译后的二进制文件 +bin/ +obj/ +*.exe +*.out +*.o + +# 忽略依赖文件 +vendor/ +node_modules/ + +# 忽略系统文件 +.DS_Store +Thumbs.db + +# 忽略 IDE 配置文件 +.vscode/ +.idea/ \ No newline at end of file diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..ac1d8b8 --- /dev/null +++ b/Makefile @@ -0,0 +1,48 @@ +# 设置变量 +PROJECT_NAME := aigrammar +SRC_DIR := src +BIN_DIR := bin +CONF_DIR := conf +OUTPUT := $(BIN_DIR)/$(PROJECT_NAME) + +# Go 编译参数 +GO := go +GOFLAGS := -mod=readonly +GOFILES := $(shell find $(SRC_DIR) -name '*.go') + +# 默认目标: 构建可执行文件 +all: build + +# 编译代码 +build: $(GOFILES) + @mkdir -p $(BIN_DIR) + $(GO) build -o $(OUTPUT) ./$(SRC_DIR)/... + @echo "✅ Build complete: $(OUTPUT)" + +# 运行程序 +run: build + $(OUTPUT) --config=$(CONF_DIR)/config.toml + +# 清理编译生成的二进制文件 +clean: + rm -rf $(BIN_DIR) + @echo "🗑 Cleaned up $(BIN_DIR)" + +# 格式化 Go 代码 +fmt: + $(GO) fmt ./$(SRC_DIR)/... + +# 整理 go.mod,清理无用依赖 +tidy: + $(GO) mod tidy + +# 显示帮助信息 +help: + @echo "Usage: make [target]" + @echo "Targets:" + @echo " all - 编译 (默认目标)" + @echo " build - 编译 Go 代码" + @echo " run - 运行编译后的程序" + @echo " clean - 删除 bin 目录" + @echo " fmt - 格式化 Go 代码" + @echo " tidy - 整理 go.mod 依赖" \ No newline at end of file diff --git a/aigrammar b/aigrammar deleted file mode 100755 index 7ccd81b..0000000 Binary files a/aigrammar and /dev/null differ diff --git a/config.toml b/conf/config.toml similarity index 83% rename from config.toml rename to conf/config.toml index bc75809..0b6e7c9 100644 --- a/config.toml +++ b/conf/config.toml @@ -4,8 +4,8 @@ jwt_secret = "mCTf-JhNRnhaaGJy_x" bind_addr = ":80" [log] -echo_log_file = "logs/echo.log" -log_file = "logs/app.log" +echo_log_file = "../log/echo.log" +log_file = "../log/app.log" max_size = 500 max_backups = 3 max_age = 28 @@ -21,7 +21,6 @@ gpt35_model = "gpt35" [database] -#mysql_conn = "172.18.0.3:3306" mysql_conn = "testdb:3306" mysql_user = "root" mysql_pass = "mysqlpw" diff --git a/gitignore b/gitignore new file mode 100644 index 0000000..23c61da --- /dev/null +++ b/gitignore @@ -0,0 +1,23 @@ +# 忽略日志文件 +log/ +logs/ +*.log + +# 忽略编译后的二进制文件 +bin/ +obj/ +*.exe +*.out +*.o + +# 忽略依赖文件 +vendor/ +node_modules/ + +# 忽略系统文件 +.DS_Store +Thumbs.db + +# 忽略 IDE 配置文件 +.vscode/ +.idea/ \ No newline at end of file diff --git a/logs/app.log b/logs/app.log deleted file mode 100644 index 6d48ef5..0000000 --- a/logs/app.log +++ /dev/null @@ -1,250 +0,0 @@ -{"level":"info","time":"2024-07-01T10:55:00.865+0800","caller":"aigrammar/main.go:29","msg":"Config loaded successfully. Azure openai ","endpoint":"https://grammar.openai.azure.com/"} -{"level":"info","time":"2024-07-01T10:55:00.865+0800","caller":"aigrammar/main.go:38","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"info","time":"2024-07-01T10:55:56.595+0800","caller":"aigrammar/main.go:29","msg":"Config loaded successfully. Azure openai ","endpoint":"https://grammar.openai.azure.com/"} -{"level":"info","time":"2024-07-01T10:55:56.595+0800","caller":"aigrammar/main.go:38","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2024-07-01T10:57:06.368+0800","caller":"aigrammar/main.go:127","msg":"into func"} -{"level":"info","time":"2024-07-01T10:57:06.374+0800","caller":"aigrammar/main.go:143","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"info","time":"2024-07-01T11:46:54.450+0800","caller":"aigrammar/main.go:38","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"info","time":"2024-07-01T11:54:34.753+0800","caller":"aigrammar/main.go:38","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2024-07-01T11:54:40.068+0800","caller":"aigrammar/iap.go:47","func":"main.IapCallbackHandler","msg":"appStoreServerNotification","appStoreServerNotification":{"Payload":{"notificationType":"SUBSCRIBED","subtype":"RESUBSCRIBE","notificationUUID":"ba289004-33f5-4622-a1ed-ee6699ef8c01","version":"2.0","signedDate":1719053019214,"summary":{"requestIdentifier":"","appAppleId":"","bundleId":"","productId":"","environment":"","storefrontCountryCodes":null,"failedCount":0,"succeededCount":0},"data":{"appAppleId":6504465465,"bundleId":"com.easyprompts.aigrammar","bundleVersion":"1","environment":"Sandbox","signedRenewalInfo":"...","signedTransactionInfo":"...","status":1},"externalPurchaseToken":{"externalPurchaseId":"","tokenCreationDate":0,"appAppleId":"","bundleId":""}},"TransactionInfo":{"appAccountToken":"","bundleId":"com.easyprompts.aigrammar","currency":"USD","environment":"Sandbox","expiresDate":1719053192000,"inAppOwnershipType":"PURCHASED","isUpgraded":false,"offerDiscountType":"","offerIdentifier":"","offerType":0,"originalPurchaseDate":1718783687000,"originalTransactionId":"2000000632564540","price":4990,"productId":"grammar_1_week","purchaseDate":1719053012000,"quantity":1,"revocationDate":0,"revocationReason":0,"signedDate":1719053019185,"storefront":"USA","storefrontId":"143441","subscriptionGroupIdentifier":"21501008","transactionId":"2000000635829288","transactionReason":"PURCHASE","type":"Auto-Renewable Subscription","webOrderLineItemId":"2000000065075723"},"RenewalInfo":{"autoRenewProductId":"grammar_1_week","autoRenewStatus":1,"environment":"Sandbox","expirationIntent":0,"gracePeriodExpiresDate":0,"isInBillingRetryPeriod":false,"offerIdentifier":"","offerType":0,"originalTransactionId":"2000000632564540","priceIncreaseStatus":0,"productId":"grammar_1_week","recentSubscriptionStartDate":1719053012000,"renewalDate":1719053192000,"signedDate":1719053019185},"IsValid":true,"IsTest":false}} -{"level":"info","time":"2024-07-01T19:05:02.862+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2024-07-01T19:05:10.837+0800","caller":"aigrammar/iap.go:47","func":"main.IapCallbackHandler","msg":"appStoreServerNotification","appStoreServerNotification":{"Payload":{"notificationType":"SUBSCRIBED","subtype":"RESUBSCRIBE","notificationUUID":"ba289004-33f5-4622-a1ed-ee6699ef8c01","version":"2.0","signedDate":1719053019214,"summary":{"requestIdentifier":"","appAppleId":"","bundleId":"","productId":"","environment":"","storefrontCountryCodes":null,"failedCount":0,"succeededCount":0},"data":{"appAppleId":6504465465,"bundleId":"com.easyprompts.aigrammar","bundleVersion":"1","environment":"Sandbox","signedRenewalInfo":"...","signedTransactionInfo":"...","status":1},"externalPurchaseToken":{"externalPurchaseId":"","tokenCreationDate":0,"appAppleId":"","bundleId":""}},"TransactionInfo":{"appAccountToken":"","bundleId":"com.easyprompts.aigrammar","currency":"USD","environment":"Sandbox","expiresDate":1719053192000,"inAppOwnershipType":"PURCHASED","isUpgraded":false,"offerDiscountType":"","offerIdentifier":"","offerType":0,"originalPurchaseDate":1718783687000,"originalTransactionId":"2000000632564540","price":4990,"productId":"grammar_1_week","purchaseDate":1719053012000,"quantity":1,"revocationDate":0,"revocationReason":0,"signedDate":1719053019185,"storefront":"USA","storefrontId":"143441","subscriptionGroupIdentifier":"21501008","transactionId":"2000000635829288","transactionReason":"PURCHASE","type":"Auto-Renewable Subscription","webOrderLineItemId":"2000000065075723"},"RenewalInfo":{"autoRenewProductId":"grammar_1_week","autoRenewStatus":1,"environment":"Sandbox","expirationIntent":0,"gracePeriodExpiresDate":0,"isInBillingRetryPeriod":false,"offerIdentifier":"","offerType":0,"originalTransactionId":"2000000632564540","priceIncreaseStatus":0,"productId":"grammar_1_week","recentSubscriptionStartDate":1719053012000,"renewalDate":1719053192000,"signedDate":1719053019185},"IsValid":true,"IsTest":false}} -{"level":"info","time":"2024-07-01T19:24:18.057+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2024-07-01T19:24:23.285+0800","caller":"aigrammar/iap.go:45","func":"main.IapCallbackHandler","msg":"appStoreServerNotification","appStoreServerNotification":{"Payload":{"notificationType":"SUBSCRIBED","subtype":"RESUBSCRIBE","notificationUUID":"ba289004-33f5-4622-a1ed-ee6699ef8c01","version":"2.0","signedDate":1719053019214,"summary":{"requestIdentifier":"","appAppleId":"","bundleId":"","productId":"","environment":"","storefrontCountryCodes":null,"failedCount":0,"succeededCount":0},"data":{"appAppleId":6504465465,"bundleId":"com.easyprompts.aigrammar","bundleVersion":"1","environment":"Sandbox","signedRenewalInfo":"...","signedTransactionInfo":"...","status":1},"externalPurchaseToken":{"externalPurchaseId":"","tokenCreationDate":0,"appAppleId":"","bundleId":""}},"TransactionInfo":{"appAccountToken":"","bundleId":"com.easyprompts.aigrammar","currency":"USD","environment":"Sandbox","expiresDate":1719053192000,"inAppOwnershipType":"PURCHASED","isUpgraded":false,"offerDiscountType":"","offerIdentifier":"","offerType":0,"originalPurchaseDate":1718783687000,"originalTransactionId":"2000000632564540","price":4990,"productId":"grammar_1_week","purchaseDate":1719053012000,"quantity":1,"revocationDate":0,"revocationReason":0,"signedDate":1719053019185,"storefront":"USA","storefrontId":"143441","subscriptionGroupIdentifier":"21501008","transactionId":"2000000635829288","transactionReason":"PURCHASE","type":"Auto-Renewable Subscription","webOrderLineItemId":"2000000065075723"},"RenewalInfo":{"autoRenewProductId":"grammar_1_week","autoRenewStatus":1,"environment":"Sandbox","expirationIntent":0,"gracePeriodExpiresDate":0,"isInBillingRetryPeriod":false,"offerIdentifier":"","offerType":0,"originalTransactionId":"2000000632564540","priceIncreaseStatus":0,"productId":"grammar_1_week","recentSubscriptionStartDate":1719053012000,"renewalDate":1719053192000,"signedDate":1719053019185},"IsValid":true,"IsTest":false}} -{"level":"debug","time":"2024-07-01T19:24:38.174+0800","caller":"aigrammar/iap.go:144","func":"main.IapHistory","msg":"transantions","transantions":[{"transactionId":"2000000632564540","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064804228","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718783686000,"originalPurchaseDate":1718783687000,"expiresDate":1718783986000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000632607914","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064807470","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718785575000,"originalPurchaseDate":1718783687000,"expiresDate":1718785875000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000632600986","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064806971","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718785275000,"originalPurchaseDate":1718783687000,"expiresDate":1718785575000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000632594963","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064806031","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718784975000,"originalPurchaseDate":1718783687000,"expiresDate":1718785275000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000632585777","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064805372","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718784586000,"originalPurchaseDate":1718783687000,"expiresDate":1718784886000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000632580459","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064804736","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718784286000,"originalPurchaseDate":1718783687000,"expiresDate":1718784586000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000634675186","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064811541","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718936544000,"originalPurchaseDate":1718783687000,"expiresDate":1718936724000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000632570259","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064804229","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718783986000,"originalPurchaseDate":1718783687000,"expiresDate":1718784286000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000632616800","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064808157","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718785875000,"originalPurchaseDate":1718783687000,"expiresDate":1718786175000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000632626808","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064808820","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718786175000,"originalPurchaseDate":1718783687000,"expiresDate":1718786475000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000632635729","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064809462","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718786475000,"originalPurchaseDate":1718783687000,"expiresDate":1718786775000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000632645557","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064810210","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718786775000,"originalPurchaseDate":1718783687000,"expiresDate":1718787075000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000632654436","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064810880","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718787075000,"originalPurchaseDate":1718783687000,"expiresDate":1718787375000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":9990,"currency":"USD"},{"transactionId":"2000000634676086","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065036695","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718936724000,"originalPurchaseDate":1718783687000,"expiresDate":1718936904000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634677314","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065036813","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718936904000,"originalPurchaseDate":1718783687000,"expiresDate":1718937084000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634678806","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065037044","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718937084000,"originalPurchaseDate":1718783687000,"expiresDate":1718937264000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634681396","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065037256","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718937264000,"originalPurchaseDate":1718783687000,"expiresDate":1718937444000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634683204","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065037472","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718937444000,"originalPurchaseDate":1718783687000,"expiresDate":1718937624000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634684881","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065037686","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718937624000,"originalPurchaseDate":1718783687000,"expiresDate":1718937804000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634686603","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065037924","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718937804000,"originalPurchaseDate":1718783687000,"expiresDate":1718937984000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833074680,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}]} -{"level":"debug","time":"2024-07-01T19:24:38.222+0800","caller":"aigrammar/iap.go:144","func":"main.IapHistory","msg":"transantions","transantions":[{"transactionId":"2000000634687801","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065038144","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718937984000,"originalPurchaseDate":1718783687000,"expiresDate":1718938164000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634689761","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065038379","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718938164000,"originalPurchaseDate":1718783687000,"expiresDate":1718938344000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634691870","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065038581","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718938344000,"originalPurchaseDate":1718783687000,"expiresDate":1718938524000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634693664","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065038825","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718938524000,"originalPurchaseDate":1718783687000,"expiresDate":1718938704000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634707050","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065039042","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718939837000,"originalPurchaseDate":1718783687000,"expiresDate":1718940017000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634708666","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065040687","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718940017000,"originalPurchaseDate":1718783687000,"expiresDate":1718940197000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634711315","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065040846","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718940197000,"originalPurchaseDate":1718783687000,"expiresDate":1718940377000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634713837","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065041077","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718940377000,"originalPurchaseDate":1718783687000,"expiresDate":1718940557000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634716473","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065041286","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718940557000,"originalPurchaseDate":1718783687000,"expiresDate":1718940737000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634718643","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065041546","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718940737000,"originalPurchaseDate":1718783687000,"expiresDate":1718940917000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634721224","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065041760","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718940949000,"originalPurchaseDate":1718783687000,"expiresDate":1718941129000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634722721","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065042066","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718941129000,"originalPurchaseDate":1718783687000,"expiresDate":1718941309000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634725574","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065042264","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718941309000,"originalPurchaseDate":1718783687000,"expiresDate":1718941489000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634727720","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065042509","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718941489000,"originalPurchaseDate":1718783687000,"expiresDate":1718941669000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634729721","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065042705","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718941669000,"originalPurchaseDate":1718783687000,"expiresDate":1718941849000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634732416","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065042943","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718941849000,"originalPurchaseDate":1718783687000,"expiresDate":1718942029000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634910910","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065061596","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718954938000,"originalPurchaseDate":1718783687000,"expiresDate":1718955118000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634915345","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065061843","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718955118000,"originalPurchaseDate":1718783687000,"expiresDate":1718955298000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634917311","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065062214","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718955298000,"originalPurchaseDate":1718783687000,"expiresDate":1718955478000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634922314","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065062522","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718955478000,"originalPurchaseDate":1718783687000,"expiresDate":1718955658000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833075977,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}]} -{"level":"debug","time":"2024-07-01T19:24:38.282+0800","caller":"aigrammar/iap.go:144","func":"main.IapHistory","msg":"transantions","transantions":[{"transactionId":"2000000634927039","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065062898","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718955658000,"originalPurchaseDate":1718783687000,"expiresDate":1718955838000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634930224","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065063325","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718955838000,"originalPurchaseDate":1718783687000,"expiresDate":1718956018000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634907981","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065043180","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718954758000,"originalPurchaseDate":1718783687000,"expiresDate":1718954938000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634935400","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065063695","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718956018000,"originalPurchaseDate":1718783687000,"expiresDate":1718956198000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634938691","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065064094","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718956198000,"originalPurchaseDate":1718783687000,"expiresDate":1718956378000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634943380","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065064430","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718956379000,"originalPurchaseDate":1718783687000,"expiresDate":1718956559000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634945557","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065064922","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718956559000,"originalPurchaseDate":1718783687000,"expiresDate":1718956739000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000634948852","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065065168","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718956739000,"originalPurchaseDate":1718783687000,"expiresDate":1718956919000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635009067","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065065508","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718959520000,"originalPurchaseDate":1718783687000,"expiresDate":1718959700000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635011389","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065071540","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718959700000,"originalPurchaseDate":1718783687000,"expiresDate":1718959880000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635014243","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065071781","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718959880000,"originalPurchaseDate":1718783687000,"expiresDate":1718960060000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635017819","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065072211","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718960060000,"originalPurchaseDate":1718783687000,"expiresDate":1718960240000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635022711","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065072564","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718960240000,"originalPurchaseDate":1718783687000,"expiresDate":1718960420000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635029249","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065073005","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718960420000,"originalPurchaseDate":1718783687000,"expiresDate":1718960600000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635033697","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065073320","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718960600000,"originalPurchaseDate":1718783687000,"expiresDate":1718960780000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635038040","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065073714","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718960780000,"originalPurchaseDate":1718783687000,"expiresDate":1718960960000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635041476","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065074180","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718960960000,"originalPurchaseDate":1718783687000,"expiresDate":1718961140000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635044825","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065074494","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718961140000,"originalPurchaseDate":1718783687000,"expiresDate":1718961320000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635051955","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065074911","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718961320000,"originalPurchaseDate":1718783687000,"expiresDate":1718961500000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635055708","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065075273","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1718961500000,"originalPurchaseDate":1718783687000,"expiresDate":1718961680000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833076750,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}]} -{"level":"debug","time":"2024-07-01T19:24:38.330+0800","caller":"aigrammar/iap.go:144","func":"main.IapHistory","msg":"transantions","transantions":[{"transactionId":"2000000635829842","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065177938","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719053192000,"originalPurchaseDate":1718783687000,"expiresDate":1719053372000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635830758","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065178027","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719053372000,"originalPurchaseDate":1718783687000,"expiresDate":1719053552000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635829288","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065075723","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719053012000,"originalPurchaseDate":1718783687000,"expiresDate":1719053192000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635831737","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065178180","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719053552000,"originalPurchaseDate":1718783687000,"expiresDate":1719053732000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635832187","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065178313","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719053732000,"originalPurchaseDate":1718783687000,"expiresDate":1719053912000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635832860","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065178451","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719053912000,"originalPurchaseDate":1718783687000,"expiresDate":1719054092000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635833567","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065178580","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719054092000,"originalPurchaseDate":1718783687000,"expiresDate":1719054272000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635834496","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065178685","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719054272000,"originalPurchaseDate":1718783687000,"expiresDate":1719054452000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635835223","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065178831","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719054452000,"originalPurchaseDate":1718783687000,"expiresDate":1719054632000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635836022","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065178944","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719054632000,"originalPurchaseDate":1718783687000,"expiresDate":1719054812000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635836843","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065179080","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719054812000,"originalPurchaseDate":1718783687000,"expiresDate":1719054992000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000635837300","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065179200","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719054992000,"originalPurchaseDate":1718783687000,"expiresDate":1719055172000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636694989","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065179324","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719215489000,"originalPurchaseDate":1718783687000,"expiresDate":1719215669000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636697274","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065289135","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719215669000,"originalPurchaseDate":1718783687000,"expiresDate":1719215849000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636699648","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065289373","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719215849000,"originalPurchaseDate":1718783687000,"expiresDate":1719216029000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636705029","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065289744","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719216029000,"originalPurchaseDate":1718783687000,"expiresDate":1719216209000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636708211","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065290085","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719216209000,"originalPurchaseDate":1718783687000,"expiresDate":1719216389000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636709887","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065290591","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719216389000,"originalPurchaseDate":1718783687000,"expiresDate":1719216569000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636715851","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065290903","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719216569000,"originalPurchaseDate":1718783687000,"expiresDate":1719216749000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636720365","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065291313","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719216749000,"originalPurchaseDate":1718783687000,"expiresDate":1719216929000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833077544,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}]} -{"level":"debug","time":"2024-07-01T19:24:38.340+0800","caller":"aigrammar/iap.go:144","func":"main.IapHistory","msg":"transantions","transantions":[{"transactionId":"2000000636724653","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065291589","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719216929000,"originalPurchaseDate":1718783687000,"expiresDate":1719217109000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833078053,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636727430","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065291925","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719217109000,"originalPurchaseDate":1718783687000,"expiresDate":1719217289000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833078053,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636730702","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065292301","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719217289000,"originalPurchaseDate":1718783687000,"expiresDate":1719217469000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833078053,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"},{"transactionId":"2000000636736591","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000065292742","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719217469000,"originalPurchaseDate":1718783687000,"expiresDate":1719217649000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719833078053,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}]} -{"level":"info","time":"2024-07-02T16:07:33.332+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2024-07-02T16:48:41.062+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-02T16:48:41.126+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"error","time":"2024-07-02T16:48:49.235+0800","caller":"aigrammar/iap.go:79","func":"main.IapVerify","msg":"GetTransactionInfo error.","error":"appstore http client do err Get \"https://api.storekit-sandbox.itunes.apple.com/inApps/v1/transactions/2000000636724654\": dial tcp: lookup api.storekit-sandbox.itunes.apple.com on 127.0.0.11:53: server misbehaving","stacktrace":"main.IapVerify\n\t/root/aigrammar/iap.go:79\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:237\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:17\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"info","time":"2024-07-02T16:54:43.637+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2024-07-02T16:54:49.565+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-02T16:54:49.566+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"error","time":"2024-07-02T16:54:57.573+0800","caller":"aigrammar/iap.go:79","func":"main.IapVerify","msg":"GetTransactionInfo error.","error":"appstore http client do err Get \"https://api.storekit-sandbox.itunes.apple.com/inApps/v1/transactions/2000000636724654\": dial tcp: lookup api.storekit-sandbox.itunes.apple.com on 127.0.0.11:53: server misbehaving","stacktrace":"main.IapVerify\n\t/root/aigrammar/iap.go:79\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:237\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"info","time":"2024-07-02T17:19:57.493+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2024-07-02T17:20:13.286+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-02T17:20:13.286+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"error","time":"2024-07-02T17:20:21.295+0800","caller":"aigrammar/iap.go:80","func":"main.IapVerify","msg":"GetTransactionInfo error.","error":"appstore http client do err Get \"https://api.storekit-sandbox.itunes.apple.com/inApps/v1/transactions/2000000636724654\": dial tcp: lookup api.storekit-sandbox.itunes.apple.com on 127.0.0.11:53: server misbehaving","stacktrace":"main.IapVerify\n\t/root/aigrammar/iap.go:80\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:237\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"debug","time":"2024-07-02T17:24:08.491+0800","caller":"aigrammar/iap.go:46","func":"main.IapCallbackHandler","msg":"appStoreServerNotification","appStoreServerNotification":{"Payload":{"notificationType":"SUBSCRIBED","subtype":"RESUBSCRIBE","notificationUUID":"ba289004-33f5-4622-a1ed-ee6699ef8c01","version":"2.0","signedDate":1719053019214,"summary":{"requestIdentifier":"","appAppleId":"","bundleId":"","productId":"","environment":"","storefrontCountryCodes":null,"failedCount":0,"succeededCount":0},"data":{"appAppleId":6504465465,"bundleId":"com.easyprompts.aigrammar","bundleVersion":"1","environment":"Sandbox","signedRenewalInfo":"...","signedTransactionInfo":"...","status":1},"externalPurchaseToken":{"externalPurchaseId":"","tokenCreationDate":0,"appAppleId":"","bundleId":""}},"TransactionInfo":{"appAccountToken":"","bundleId":"com.easyprompts.aigrammar","currency":"USD","environment":"Sandbox","expiresDate":1719053192000,"inAppOwnershipType":"PURCHASED","isUpgraded":false,"offerDiscountType":"","offerIdentifier":"","offerType":0,"originalPurchaseDate":1718783687000,"originalTransactionId":"2000000632564540","price":4990,"productId":"grammar_1_week","purchaseDate":1719053012000,"quantity":1,"revocationDate":0,"revocationReason":0,"signedDate":1719053019185,"storefront":"USA","storefrontId":"143441","subscriptionGroupIdentifier":"21501008","transactionId":"2000000635829288","transactionReason":"PURCHASE","type":"Auto-Renewable Subscription","webOrderLineItemId":"2000000065075723"},"RenewalInfo":{"autoRenewProductId":"grammar_1_week","autoRenewStatus":1,"environment":"Sandbox","expirationIntent":0,"gracePeriodExpiresDate":0,"isInBillingRetryPeriod":false,"offerIdentifier":"","offerType":0,"originalTransactionId":"2000000632564540","priceIncreaseStatus":0,"productId":"grammar_1_week","recentSubscriptionStartDate":1719053012000,"renewalDate":1719053192000,"signedDate":1719053019185},"IsValid":true,"IsTest":false}} -{"level":"info","time":"2024-07-02T17:29:03.449+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2024-07-02T17:29:08.296+0800","caller":"aigrammar/iap.go:46","func":"main.IapCallbackHandler","msg":"appStoreServerNotification","appStoreServerNotification":{"Payload":{"notificationType":"SUBSCRIBED","subtype":"RESUBSCRIBE","notificationUUID":"ba289004-33f5-4622-a1ed-ee6699ef8c01","version":"2.0","signedDate":1719053019214,"summary":{"requestIdentifier":"","appAppleId":"","bundleId":"","productId":"","environment":"","storefrontCountryCodes":null,"failedCount":0,"succeededCount":0},"data":{"appAppleId":6504465465,"bundleId":"com.easyprompts.aigrammar","bundleVersion":"1","environment":"Sandbox","signedRenewalInfo":"...","signedTransactionInfo":"...","status":1},"externalPurchaseToken":{"externalPurchaseId":"","tokenCreationDate":0,"appAppleId":"","bundleId":""}},"TransactionInfo":{"appAccountToken":"","bundleId":"com.easyprompts.aigrammar","currency":"USD","environment":"Sandbox","expiresDate":1719053192000,"inAppOwnershipType":"PURCHASED","isUpgraded":false,"offerDiscountType":"","offerIdentifier":"","offerType":0,"originalPurchaseDate":1718783687000,"originalTransactionId":"2000000632564540","price":4990,"productId":"grammar_1_week","purchaseDate":1719053012000,"quantity":1,"revocationDate":0,"revocationReason":0,"signedDate":1719053019185,"storefront":"USA","storefrontId":"143441","subscriptionGroupIdentifier":"21501008","transactionId":"2000000635829288","transactionReason":"PURCHASE","type":"Auto-Renewable Subscription","webOrderLineItemId":"2000000065075723"},"RenewalInfo":{"autoRenewProductId":"grammar_1_week","autoRenewStatus":1,"environment":"Sandbox","expirationIntent":0,"gracePeriodExpiresDate":0,"isInBillingRetryPeriod":false,"offerIdentifier":"","offerType":0,"originalTransactionId":"2000000632564540","priceIncreaseStatus":0,"productId":"grammar_1_week","recentSubscriptionStartDate":1719053012000,"renewalDate":1719053192000,"signedDate":1719053019185},"IsValid":true,"IsTest":false}} -{"level":"error","time":"2024-07-02T17:29:08.453+0800","caller":"aigrammar/user.go:199","func":"main.UpdateOrderByNotify","msg":"UpdateOrderByNotify","error":"Error 1146 (42S02): Table 'aigrammar.order_log' doesn't exist","stacktrace":"main.UpdateOrderByNotify\n\t/root/aigrammar/user.go:199\nmain.IapCallbackHandler\n\t/root/aigrammar/iap.go:51\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"debug","time":"2024-07-02T17:30:30.296+0800","caller":"aigrammar/iap.go:46","func":"main.IapCallbackHandler","msg":"appStoreServerNotification","appStoreServerNotification":{"Payload":{"notificationType":"SUBSCRIBED","subtype":"RESUBSCRIBE","notificationUUID":"ba289004-33f5-4622-a1ed-ee6699ef8c01","version":"2.0","signedDate":1719053019214,"summary":{"requestIdentifier":"","appAppleId":"","bundleId":"","productId":"","environment":"","storefrontCountryCodes":null,"failedCount":0,"succeededCount":0},"data":{"appAppleId":6504465465,"bundleId":"com.easyprompts.aigrammar","bundleVersion":"1","environment":"Sandbox","signedRenewalInfo":"...","signedTransactionInfo":"...","status":1},"externalPurchaseToken":{"externalPurchaseId":"","tokenCreationDate":0,"appAppleId":"","bundleId":""}},"TransactionInfo":{"appAccountToken":"","bundleId":"com.easyprompts.aigrammar","currency":"USD","environment":"Sandbox","expiresDate":1719053192000,"inAppOwnershipType":"PURCHASED","isUpgraded":false,"offerDiscountType":"","offerIdentifier":"","offerType":0,"originalPurchaseDate":1718783687000,"originalTransactionId":"2000000632564540","price":4990,"productId":"grammar_1_week","purchaseDate":1719053012000,"quantity":1,"revocationDate":0,"revocationReason":0,"signedDate":1719053019185,"storefront":"USA","storefrontId":"143441","subscriptionGroupIdentifier":"21501008","transactionId":"2000000635829288","transactionReason":"PURCHASE","type":"Auto-Renewable Subscription","webOrderLineItemId":"2000000065075723"},"RenewalInfo":{"autoRenewProductId":"grammar_1_week","autoRenewStatus":1,"environment":"Sandbox","expirationIntent":0,"gracePeriodExpiresDate":0,"isInBillingRetryPeriod":false,"offerIdentifier":"","offerType":0,"originalTransactionId":"2000000632564540","priceIncreaseStatus":0,"productId":"grammar_1_week","recentSubscriptionStartDate":1719053012000,"renewalDate":1719053192000,"signedDate":1719053019185},"IsValid":true,"IsTest":false}} -{"level":"debug","time":"2024-07-02T17:37:40.582+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-02T17:37:40.583+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"info","time":"2024-07-02T17:37:40.583+0800","caller":"aigrammar/translate.go:153","func":"main.TranslateFeedBackHandler","msg":"feedback","ID":10001,"feedback":{"product":"trans","input":"This is a demo text with more complex grammar checking algorithm of the pro version. ","output":"","res":"good"}} -{"level":"debug","time":"2024-07-02T18:21:46.498+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-02T18:21:46.503+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"error","time":"2024-07-02T18:21:48.119+0800","caller":"aigrammar/iap.go:81","func":"main.IapVerify","msg":"GetTransactionInfo error.","error":"errorCode: 4040010, errorMessage: Transaction id not found.","stacktrace":"main.IapVerify\n\t/root/aigrammar/iap.go:81\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:237\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"debug","time":"2024-07-02T18:22:29.226+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-02T18:22:29.227+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"error","time":"2024-07-02T18:22:29.628+0800","caller":"aigrammar/iap.go:81","func":"main.IapVerify","msg":"GetTransactionInfo error.","error":"errorCode: 4040010, errorMessage: Transaction id not found.","stacktrace":"main.IapVerify\n\t/root/aigrammar/iap.go:81\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:237\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"debug","time":"2024-07-03T11:52:23.588+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-03T11:52:23.612+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"debug","time":"2024-07-03T11:52:24.838+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000645433302","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066269010","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1719978588000,"originalPurchaseDate":1718783687000,"expiresDate":1719978768000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1719978744783,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-03T11:53:23.071+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-03T11:53:23.071+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"debug","time":"2024-07-03T11:53:23.447+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000632564540","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064804228","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718783686000,"originalPurchaseDate":1718783687000,"expiresDate":1718783986000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1719978803433,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":9990,"currency":"USD"}} -{"level":"debug","time":"2024-07-03T16:47:29.660+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"fatal","time":"2024-07-03T16:47:29.690+0800","caller":"aigrammar/main.go:142","func":"main.parseToken","msg":"ParaseToken Error.","error":"json: cannot unmarshal string into Go struct field jwtCustomClaims.gid of type int","stacktrace":"main.parseToken\n\t/root/aigrammar/main.go:142\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:227\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"info","time":"2024-07-03T18:06:41.391+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2024-07-03T18:29:57.881+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-03T18:29:57.899+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"debug","time":"2024-07-03T18:29:58.771+0800","caller":"aigrammar/user.go:50","func":"main.queryUserHandler","msg":"insert user","ID":10002,"DeviceID":"12345ABC"} -{"level":"debug","time":"2024-07-04T08:46:10.760+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T08:46:10.781+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"error","time":"2024-07-04T08:46:11.074+0800","caller":"aigrammar/user.go:53","func":"main.queryUserHandler","msg":"query db error","error":"sql: Scan error on column index 1, name \"UserID\": converting NULL to string is unsupported","stacktrace":"main.queryUserHandler\n\t/root/aigrammar/user.go:53\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:237\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"debug","time":"2024-07-04T09:03:49.593+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T09:03:49.597+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"error","time":"2024-07-04T09:03:49.626+0800","caller":"aigrammar/user.go:40","func":"main.queryUserHandler","msg":"insert db error","error":"Error 1364 (HY000): Field 'UserID' doesn't have a default value","stacktrace":"main.queryUserHandler\n\t/root/aigrammar/user.go:40\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:237\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"debug","time":"2024-07-04T09:05:34.000+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T09:05:34.000+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"debug","time":"2024-07-04T09:05:34.021+0800","caller":"aigrammar/user.go:50","func":"main.queryUserHandler","msg":"insert user","ID":10003,"DeviceID":"12345ABC"} -{"level":"debug","time":"2024-07-04T09:12:22.250+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T09:12:22.250+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":0,"exp1":1720141941}} -{"level":"debug","time":"2024-07-04T09:12:22.267+0800","caller":"aigrammar/user.go:50","func":"main.queryUserHandler","msg":"insert user","ID":10004,"DeviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0"} -{"level":"debug","time":"2024-07-04T09:36:48.945+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T09:36:48.947+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":0,"exp1":1720143408}} -{"level":"warn","time":"2024-07-04T09:36:49.010+0800","caller":"aigrammar/user.go:58","func":"main.queryUserHandler","msg":"userid not match","ID":10004,"userGID":0} -{"level":"debug","time":"2024-07-04T11:10:44.680+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T11:10:44.693+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"debug","time":"2024-07-04T11:10:46.872+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000632564540","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000064804228","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_month","subscriptionGroupIdentifier":"21501008","purchaseDate":1718783686000,"originalPurchaseDate":1718783687000,"expiresDate":1718783986000,"quantity":1,"type":"Auto-Renewable Subscription","inAppOwnershipType":"PURCHASED","signedDate":1720062646583,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":9990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:15:31.367+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:15:31.380+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":0,"exp1":1720170931}} -{"level":"warn","time":"2024-07-04T17:15:31.500+0800","caller":"aigrammar/user.go:58","func":"main.queryUserHandler","msg":"userid not match","ID":10004,"userGID":0} -{"level":"debug","time":"2024-07-04T17:21:26.895+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:21:26.895+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720171287}} -{"level":"debug","time":"2024-07-04T17:21:29.271+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647114476","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066270487","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720084879000,"originalPurchaseDate":1718783687000,"expiresDate":1720085059000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720084889493,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:21:32.795+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:21:32.795+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720171293}} -{"level":"debug","time":"2024-07-04T17:21:33.102+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647114476","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066270487","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720084879000,"originalPurchaseDate":1718783687000,"expiresDate":1720085059000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720084893324,"storefront":"USA","storefrontId":"143441","transactionReason":"PURCHASE","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:24:01.102+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:24:01.103+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720171441}} -{"level":"debug","time":"2024-07-04T17:24:02.361+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647118383","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066432653","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085059000,"originalPurchaseDate":1718783687000,"expiresDate":1720085239000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085042529,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:24:02.482+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:24:02.483+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720171442}} -{"level":"debug","time":"2024-07-04T17:24:02.787+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647118383","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066432653","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085059000,"originalPurchaseDate":1718783687000,"expiresDate":1720085239000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085043004,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:26:45.741+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:26:45.741+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720171606}} -{"level":"debug","time":"2024-07-04T17:26:46.981+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647121654","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066433014","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085239000,"originalPurchaseDate":1718783687000,"expiresDate":1720085419000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085207136,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:26:48.157+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:26:48.158+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720171608}} -{"level":"debug","time":"2024-07-04T17:26:48.687+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647121654","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066433014","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085239000,"originalPurchaseDate":1718783687000,"expiresDate":1720085419000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085208697,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:29:28.366+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:29:28.366+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720171768}} -{"level":"debug","time":"2024-07-04T17:29:29.674+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647125706","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066433428","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085419000,"originalPurchaseDate":1718783687000,"expiresDate":1720085599000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085369906,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:29:30.688+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:29:30.688+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720171771}} -{"level":"debug","time":"2024-07-04T17:29:31.217+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647125706","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066433428","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085419000,"originalPurchaseDate":1718783687000,"expiresDate":1720085599000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085371231,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:32:40.583+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:32:40.583+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720171960}} -{"level":"debug","time":"2024-07-04T17:32:41.727+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647131024","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066433852","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085599000,"originalPurchaseDate":1718783687000,"expiresDate":1720085779000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085561796,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:32:42.576+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:32:42.576+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720171962}} -{"level":"debug","time":"2024-07-04T17:32:43.105+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647131024","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066433852","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085599000,"originalPurchaseDate":1718783687000,"expiresDate":1720085779000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085563102,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:37:02.306+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:37:02.307+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720172222}} -{"level":"debug","time":"2024-07-04T17:37:03.542+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647136212","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066434239","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085812000,"originalPurchaseDate":1718783687000,"expiresDate":1720085992000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085823694,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:37:04.305+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:37:04.305+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720172224}} -{"level":"debug","time":"2024-07-04T17:37:04.745+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647136212","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066434239","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085812000,"originalPurchaseDate":1718783687000,"expiresDate":1720085992000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085824829,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:39:03.963+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:39:03.964+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720172343}} -{"level":"debug","time":"2024-07-04T17:39:05.323+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:39:05.323+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720172345}} -{"level":"debug","time":"2024-07-04T17:39:05.845+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647139324","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066434905","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085992000,"originalPurchaseDate":1718783687000,"expiresDate":1720086172000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085946080,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:39:05.889+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647139324","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066434905","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720085992000,"originalPurchaseDate":1718783687000,"expiresDate":1720086172000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720085946086,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:42:23.103+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:42:23.104+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720172543}} -{"level":"debug","time":"2024-07-04T17:42:24.408+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647143789","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066435228","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720086172000,"originalPurchaseDate":1718783687000,"expiresDate":1720086352000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720086144553,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:42:25.225+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:42:25.226+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720172545}} -{"level":"debug","time":"2024-07-04T17:42:25.587+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647143789","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066435228","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720086172000,"originalPurchaseDate":1718783687000,"expiresDate":1720086352000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720086145759,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:45:14.229+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:45:14.229+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720172714}} -{"level":"debug","time":"2024-07-04T17:45:15.392+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647148013","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066435721","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720086352000,"originalPurchaseDate":1718783687000,"expiresDate":1720086532000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720086315539,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:45:16.239+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:45:16.239+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720172716}} -{"level":"debug","time":"2024-07-04T17:45:16.579+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647148013","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066435721","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720086352000,"originalPurchaseDate":1718783687000,"expiresDate":1720086532000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720086316767,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:48:35.469+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:48:35.469+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720172915}} -{"level":"debug","time":"2024-07-04T17:48:36.632+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647152998","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066436156","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720086532000,"originalPurchaseDate":1718783687000,"expiresDate":1720086712000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720086516861,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:48:37.561+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:48:37.561+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720172917}} -{"level":"debug","time":"2024-07-04T17:48:37.904+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647152998","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066436156","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720086532000,"originalPurchaseDate":1718783687000,"expiresDate":1720086712000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720086518101,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:51:15.730+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:51:15.730+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720173075}} -{"level":"debug","time":"2024-07-04T17:51:16.540+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647156876","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066436641","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720086712000,"originalPurchaseDate":1718783687000,"expiresDate":1720086892000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720086676775,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:51:18.002+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:51:18.002+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720173078}} -{"level":"debug","time":"2024-07-04T17:51:18.529+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647156876","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066436641","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720086712000,"originalPurchaseDate":1718783687000,"expiresDate":1720086892000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720086678529,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:53:33.780+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:53:33.780+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":0,"exp1":1720173213}} -{"level":"warn","time":"2024-07-04T17:53:33.841+0800","caller":"aigrammar/user.go:58","func":"main.queryUserHandler","msg":"userid not match","ID":10004,"userGID":0} -{"level":"debug","time":"2024-07-04T17:54:17.269+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:54:17.269+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720173257}} -{"level":"debug","time":"2024-07-04T17:54:18.580+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647161974","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066437033","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720086892000,"originalPurchaseDate":1718783687000,"expiresDate":1720087072000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720086858717,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:54:19.371+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:54:19.372+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720173259}} -{"level":"debug","time":"2024-07-04T17:54:19.739+0800","caller":"aigrammar/iap.go:91","func":"main.IapVerify","msg":"transantion","transantion":{"transactionId":"2000000647161974","originalTransactionId":"2000000632564540","webOrderLineItemId":"2000000066437033","bundleId":"com.easyprompts.aigrammar","productId":"grammar_1_week","subscriptionGroupIdentifier":"21501008","purchaseDate":1720086892000,"originalPurchaseDate":1718783687000,"expiresDate":1720087072000,"quantity":1,"type":"Auto-Renewable Subscription","appAccountToken":"e2fde03b-c5ab-46a3-aacc-2d96c6bbeb84","inAppOwnershipType":"PURCHASED","signedDate":1720086859904,"storefront":"USA","storefrontId":"143441","transactionReason":"RENEWAL","environment":"Sandbox","price":4990,"currency":"USD"}} -{"level":"debug","time":"2024-07-04T17:57:38.723+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T17:57:38.723+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":0,"exp1":1720173458}} -{"level":"warn","time":"2024-07-04T17:57:38.726+0800","caller":"aigrammar/user.go:58","func":"main.queryUserHandler","msg":"userid not match","ID":10004,"userGID":0} -{"level":"debug","time":"2024-07-04T19:07:28.264+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T19:07:28.268+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"debug","time":"2024-07-04T19:07:28.442+0800","caller":"aigrammar/user.go:131","func":"main.queryUserBenefits","msg":"CheckAndDecrement","ID":10001,"timeZone":"Asia/Shanghai","secondsFromGMT":28800,"status":0} -{"level":"warn","time":"2024-07-04T19:07:40.832+0800","caller":"aigrammar/translate.go:229","func":"main.gTranslate","msg":"filterd","Hate":"safe","Hate-filtered":false,"SelfHarm":"safe","SelfHarm-filtered":false,"Sexual":"safe","Sexual-filtered":false,"Violence":"safe","Violence-filtered":false,"Error":"no content","input":"This is a demo text with more complex grammar checking algorithm of the pro version. This app have been designed to help you to write correctly and appear more professional. I work really hard to make this app as god as possible. If you are happy with the results, please consider supporting the app by subscribing to the PRO plan. The text writen here is to show you how much the app is capable of with the pro version. is this something you would like to use?"} -{"level":"debug","time":"2024-07-04T19:07:40.834+0800","caller":"aigrammar/translate.go:248","func":"main.gTranslate","msg":"Finish Reason","index":0,"reason":"stop"} -{"level":"info","time":"2024-07-04T19:07:40.834+0800","caller":"aigrammar/translate.go:48","func":"main.TranslateHandler","msg":"translation","ID":10001,"input":"This is a demo text with more complex grammar checking algorithm of the pro version. This app have been designed to help you to write correctly and appear more professional. I work really hard to make this app as god as possible. If you are happy with the results, please consider supporting the app by subscribing to the PRO plan. The text writen here is to show you how much the app is capable of with the pro version. is this something you would like to use?","output":"这是一个演示文本,具有更复杂的语法检查算法,属于专业版的功能。该应用程序旨在帮助您进行正确的书写,展现更专业的一面。我非常努力地使这款应用尽可能地好。如果您对结果满意,希望您能考虑支持该应用,订阅PRO计划。这里写的文字展示了应用在专业版下的强大能力。这是您想要使用的吗?"} -{"level":"debug","time":"2024-07-04T19:07:52.760+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T19:07:52.761+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10002,"exp1":1727974853}} -{"level":"debug","time":"2024-07-04T19:07:52.770+0800","caller":"aigrammar/user.go:131","func":"main.queryUserBenefits","msg":"CheckAndDecrement","ID":10002,"timeZone":"Asia/Shanghai","secondsFromGMT":28800,"status":0} -{"level":"warn","time":"2024-07-04T19:08:08.220+0800","caller":"aigrammar/translate.go:229","func":"main.gTranslate","msg":"filterd","Hate":"safe","Hate-filtered":false,"SelfHarm":"safe","SelfHarm-filtered":false,"Sexual":"safe","Sexual-filtered":false,"Violence":"safe","Violence-filtered":false,"Error":"no content","input":"This is a demo text with more complex grammar checking algorithm of the pro version. This app have been designed to help you to write correctly and appear more professional. I work really hard to make this app as god as possible. If you are happy with the results, please consider supporting the app by subscribing to the PRO plan. The text writen here is to show you how much the app is capable of with the pro version. is this something you would like to use?"} -{"level":"debug","time":"2024-07-04T19:08:08.223+0800","caller":"aigrammar/translate.go:248","func":"main.gTranslate","msg":"Finish Reason","index":0,"reason":"stop"} -{"level":"info","time":"2024-07-04T19:08:08.223+0800","caller":"aigrammar/translate.go:90","func":"main.GrammarHandler","msg":"grammar","ID":10002,"input":"This is a demo text with more complex grammar checking algorithm of the pro version. This app have been designed to help you to write correctly and appear more professional. I work really hard to make this app as god as possible. If you are happy with the results, please consider supporting the app by subscribing to the PRO plan. The text writen here is to show you how much the app is capable of with the pro version. is this something you would like to use?","output":[{"correction":["This app has"],"plain":"This app have","reason":"Subject-verb agreement error","type":"grammar"},{"correction":["as good as possible"],"plain":"as god as possible","reason":"Typo","type":"spell"},{"correction":["The text written"],"plain":"The text writen","reason":"Spelling error","type":"spell"},{"correction":["of in the pro","of using the pro"],"plain":"of with the pro","reason":"Preposition misuse","type":"grammar"}]} -{"level":"debug","time":"2024-07-04T19:10:23.185+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-04T19:10:23.185+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"debug","time":"2024-07-04T19:10:23.203+0800","caller":"aigrammar/user.go:131","func":"main.queryUserBenefits","msg":"CheckAndDecrement","ID":10001,"timeZone":"Asia/Shanghai","secondsFromGMT":28800,"status":0} -{"level":"warn","time":"2024-07-04T19:10:37.547+0800","caller":"aigrammar/translate.go:229","func":"main.gTranslate","msg":"filterd","Hate":"safe","Hate-filtered":false,"SelfHarm":"safe","SelfHarm-filtered":false,"Sexual":"safe","Sexual-filtered":false,"Violence":"safe","Violence-filtered":false,"Error":"no content","input":"check"} -{"level":"debug","time":"2024-07-04T19:10:37.547+0800","caller":"aigrammar/translate.go:248","func":"main.gTranslate","msg":"Finish Reason","index":0,"reason":"stop"} -{"level":"info","time":"2024-07-04T19:10:37.547+0800","caller":"aigrammar/translate.go:129","func":"main.WordsHandler","msg":"words","ID":10001,"input":"check","output":{"explain":["to examine something in order to make sure that it is correct or the way it should be","a written instruction to your bank to pay money from your account","an act of stopping somebody/something from moving or developing freely"],"phrase":["check your work","write a check","put a check on"],"sync":["examine","inspect","verify","scrutinize","probe"],"word":"check"}} -{"level":"debug","time":"2024-07-05T08:37:44.716+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-05T08:37:44.736+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":0,"exp1":1720226264}} -{"level":"warn","time":"2024-07-05T08:37:44.948+0800","caller":"aigrammar/user.go:58","func":"main.queryUserHandler","msg":"userid not match","ID":10004,"userGID":0} -{"level":"debug","time":"2024-07-05T08:50:34.211+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-05T08:50:34.213+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720227034}} -{"level":"debug","time":"2024-07-05T08:50:34.293+0800","caller":"aigrammar/user.go:131","func":"main.queryUserBenefits","msg":"CheckAndDecrement","ID":10004,"timeZone":"","secondsFromGMT":0,"status":0} -{"level":"warn","time":"2024-07-05T08:50:41.120+0800","caller":"aigrammar/translate.go:229","func":"main.gTranslate","msg":"filterd","Hate":"safe","Hate-filtered":false,"SelfHarm":"safe","SelfHarm-filtered":false,"Sexual":"safe","Sexual-filtered":false,"Violence":"safe","Violence-filtered":false,"Error":"no content","input":"This is a demo text with more complex grammar checking algorithm of the pro version. This app have been designed to help you to write correctly and appear more professional. I work really hard to make this app as god as possible. If you are happy with the results, please consider supporting the app by subscribing to the PRO plan. The text writen here is to show you how much the app is capable of with the pro version. is this something you would like to use? "} -{"level":"debug","time":"2024-07-05T08:50:41.120+0800","caller":"aigrammar/translate.go:248","func":"main.gTranslate","msg":"Finish Reason","index":0,"reason":"stop"} -{"level":"info","time":"2024-07-05T08:50:41.120+0800","caller":"aigrammar/translate.go:90","func":"main.GrammarHandler","msg":"grammar","ID":10004,"input":"This is a demo text with more complex grammar checking algorithm of the pro version. This app have been designed to help you to write correctly and appear more professional. I work really hard to make this app as god as possible. If you are happy with the results, please consider supporting the app by subscribing to the PRO plan. The text writen here is to show you how much the app is capable of with the pro version. is this something you would like to use? ","output":[{"correction":["This app has been"],"plain":"This app have been","reason":"subject-verb agreement","type":"grammar"},{"correction":["as good as"],"plain":"as god as","reason":"incorrect spelling","type":"spell"},{"correction":["The text written"],"plain":"The text writen","reason":"incorrect spelling","type":"spell"},{"correction":["you the app's capabilities"],"plain":"you how much the app is capable","reason":"unnatural expression","type":"grammar"}]} -{"level":"debug","time":"2024-07-05T08:56:09.588+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-05T08:56:09.588+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720227369}} -{"level":"debug","time":"2024-07-05T08:56:09.634+0800","caller":"aigrammar/user.go:131","func":"main.queryUserBenefits","msg":"CheckAndDecrement","ID":10004,"timeZone":"","secondsFromGMT":0,"status":0} -{"level":"warn","time":"2024-07-05T08:56:16.719+0800","caller":"aigrammar/translate.go:229","func":"main.gTranslate","msg":"filterd","Hate":"safe","Hate-filtered":false,"SelfHarm":"safe","SelfHarm-filtered":false,"Sexual":"safe","Sexual-filtered":false,"Violence":"safe","Violence-filtered":false,"Error":"no content","input":"This is a demo text with more complex grammar checking algorithm of the pro version. This app have been designed to help you to write correctly and appear more professional. I work really hard to make this app as god as possible. If you are happy with the results, please consider supporting the app by subscribing to the PRO plan. The text writen here is to show you how much the app is capable of with the pro version. is this something you would like to use? "} -{"level":"debug","time":"2024-07-05T08:56:16.719+0800","caller":"aigrammar/translate.go:248","func":"main.gTranslate","msg":"Finish Reason","index":0,"reason":"stop"} -{"level":"info","time":"2024-07-05T08:56:16.720+0800","caller":"aigrammar/translate.go:90","func":"main.GrammarHandler","msg":"grammar","ID":10004,"input":"This is a demo text with more complex grammar checking algorithm of the pro version. This app have been designed to help you to write correctly and appear more professional. I work really hard to make this app as god as possible. If you are happy with the results, please consider supporting the app by subscribing to the PRO plan. The text writen here is to show you how much the app is capable of with the pro version. is this something you would like to use? ","output":[{"correction":["This app has"],"plain":"This app have","reason":"subject-verb disagreement","type":"grammar"},{"correction":["as good as"],"plain":"as god as","reason":"mis-spelled word","type":"spell"},{"correction":["The text written"],"plain":"The text writen","reason":"mis-spelled word","type":"spell"},{"correction":["Is this"],"plain":"is this","reason":"start with Capital letter","type":"grammar"}]} -{"level":"debug","time":"2024-07-05T08:58:22.905+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-05T08:58:22.906+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720227502}} -{"level":"debug","time":"2024-07-05T08:58:22.909+0800","caller":"aigrammar/user.go:131","func":"main.queryUserBenefits","msg":"CheckAndDecrement","ID":10004,"timeZone":"","secondsFromGMT":0,"status":0} -{"level":"warn","time":"2024-07-05T08:58:28.500+0800","caller":"aigrammar/translate.go:229","func":"main.gTranslate","msg":"filterd","Hate":"safe","Hate-filtered":false,"SelfHarm":"safe","SelfHarm-filtered":false,"Sexual":"safe","Sexual-filtered":false,"Violence":"safe","Violence-filtered":false,"Error":"no content","input":"Failure "} -{"level":"debug","time":"2024-07-05T08:58:28.500+0800","caller":"aigrammar/translate.go:248","func":"main.gTranslate","msg":"Finish Reason","index":0,"reason":"stop"} -{"level":"info","time":"2024-07-05T08:58:28.500+0800","caller":"aigrammar/translate.go:129","func":"main.WordsHandler","msg":"words","ID":10004,"input":"Failure ","output":{"explain":["The condition or fact of not achieving the desired end or ends","The cessation of proper functioning or performance","Non-performance of something due, required, or expected"],"phrase":["failure to communicate","failure of the project","The failure of the crops was a disaster"],"synonyms":["Defeat","Downfall","Fiasco","Mishap","Collapse"],"word":"Failure"}} -{"level":"debug","time":"2024-07-05T08:59:33.027+0800","caller":"aigrammar/main.go:132","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-05T08:59:33.027+0800","caller":"aigrammar/main.go:147","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720227573}} -{"level":"debug","time":"2024-07-05T08:59:33.034+0800","caller":"aigrammar/user.go:131","func":"main.queryUserBenefits","msg":"CheckAndDecrement","ID":10004,"timeZone":"","secondsFromGMT":0,"status":1} -{"level":"error","time":"2024-07-05T08:59:33.034+0800","caller":"aigrammar/translate.go:37","func":"main.TranslateHandler","msg":"user beyond limit.","ID":10004,"input":"The app is available on the App Store ","stacktrace":"main.TranslateHandler\n\t/root/aigrammar/translate.go:37\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:237\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"debug","time":"2024-07-05T09:03:06.235+0800","caller":"aigrammar/user.go:91","func":"main.UserRightsHandler","msg":"QueryUserBenefits","userData":"{}","ID":0} -{"level":"debug","time":"2024-07-05T09:05:35.780+0800","caller":"aigrammar/user.go:91","func":"main.UserRightsHandler","msg":"QueryUserBenefits","userData":"{\"10004:20240705\":0}","ID":10004} -{"level":"info","time":"2024-07-05T09:32:29.773+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"info","time":"2024-07-05T09:33:17.727+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2024-07-05T09:33:56.492+0800","caller":"aigrammar/user.go:113","func":"main.ResetUserRightsHandler","msg":"ResetUserRightsHandler","ID":10004} -{"level":"debug","time":"2024-07-05T09:34:05.259+0800","caller":"aigrammar/user.go:91","func":"main.UserRightsHandler","msg":"QueryUserBenefits","userData":"{}","ID":10004} -{"level":"debug","time":"2024-07-05T09:34:11.214+0800","caller":"aigrammar/main.go:133","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-07-05T09:34:11.215+0800","caller":"aigrammar/main.go:148","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"23b64185cd304e238a591a778454951693e8aa91ee8d247e16629881cecd17c0","gid":10004,"exp1":1720229651}} -{"level":"debug","time":"2024-07-05T09:34:11.327+0800","caller":"aigrammar/user.go:153","func":"main.queryUserBenefits","msg":"CheckAndDecrement","ID":10004,"timeZone":"","secondsFromGMT":0,"status":0} -{"level":"warn","time":"2024-07-05T09:34:14.237+0800","caller":"aigrammar/translate.go:229","func":"main.gTranslate","msg":"filterd","Hate":"safe","Hate-filtered":false,"SelfHarm":"safe","SelfHarm-filtered":false,"Sexual":"safe","Sexual-filtered":false,"Violence":"safe","Violence-filtered":false,"Error":"no content","input":"The app is available on the App Store "} -{"level":"debug","time":"2024-07-05T09:34:14.238+0800","caller":"aigrammar/translate.go:248","func":"main.gTranslate","msg":"Finish Reason","index":0,"reason":"stop"} -{"level":"info","time":"2024-07-05T09:34:14.238+0800","caller":"aigrammar/translate.go:48","func":"main.TranslateHandler","msg":"translation","ID":10004,"input":"The app is available on the App Store ","output":"这款应用程序在App Store上可用。"} -{"level":"debug","time":"2024-07-05T09:45:11.394+0800","caller":"aigrammar/user.go:91","func":"main.UserRightsHandler","msg":"QueryUserBenefits","userData":"{\"10004_20240705\":2}","ID":10004} -{"level":"info","time":"2024-08-01T17:47:38.837+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"info","time":"2024-08-01T17:48:33.705+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.4:3306"} -{"level":"debug","time":"2024-08-01T17:49:18.435+0800","caller":"aigrammar/user.go:91","func":"main.UserRightsHandler","msg":"QueryUserBenefits","userData":"{}","ID":10004} -{"level":"debug","time":"2024-08-01T17:49:28.746+0800","caller":"aigrammar/main.go:133","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-08-01T17:49:28.750+0800","caller":"aigrammar/main.go:148","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"debug","time":"2024-08-01T17:49:28.768+0800","caller":"aigrammar/user.go:153","func":"main.queryUserBenefits","msg":"CheckAndDecrement","ID":10001,"timeZone":"Asia/Shanghai","secondsFromGMT":28800,"status":0} -{"level":"warn","time":"2024-08-01T17:49:38.159+0800","caller":"aigrammar/translate.go:229","func":"main.gTranslate","msg":"filterd","Hate":"safe","Hate-filtered":false,"SelfHarm":"safe","SelfHarm-filtered":false,"Sexual":"safe","Sexual-filtered":false,"Violence":"safe","Violence-filtered":false,"Error":"no content","input":"check"} -{"level":"debug","time":"2024-08-01T17:49:38.160+0800","caller":"aigrammar/translate.go:248","func":"main.gTranslate","msg":"Finish Reason","index":0,"reason":"stop"} -{"level":"info","time":"2024-08-01T17:49:38.161+0800","caller":"aigrammar/translate.go:129","func":"main.WordsHandler","msg":"words","ID":10001,"input":"check","output":{"explain":["To examine something in order to be certain that it is correct, safe, or suitable","A small piece of printed paper that you can use instead of money","To stop someone from doing what they are trying to do"],"phrase":["Check your pockets","Write a check","Check the brakes"],"sync":["verify","inspect","halt","examine","veto"],"word":"check"}} -{"level":"info","time":"2024-08-01T18:56:13.305+0800","caller":"aigrammar/main.go:41","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.4:3306"} -{"level":"debug","time":"2024-08-01T18:56:25.190+0800","caller":"aigrammar/main.go:133","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-08-01T18:56:25.196+0800","caller":"aigrammar/main.go:148","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"error","time":"2024-08-01T18:56:25.199+0800","caller":"aigrammar/user.go:157","func":"main.queryUserBenefits","msg":"query db error","error":"dial tcp 172.18.0.4:3306: connect: connection refused","stacktrace":"main.queryUserBenefits\n\t/root/aigrammar/user.go:157\nmain.WordsHandler\n\t/root/aigrammar/translate.go:110\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:237\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"error","time":"2024-08-01T18:56:25.200+0800","caller":"aigrammar/translate.go:111","func":"main.WordsHandler","msg":"user beyond limit.","ID":10001,"input":"check","stacktrace":"main.WordsHandler\n\t/root/aigrammar/translate.go:111\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:237\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"debug","time":"2024-08-01T18:56:35.139+0800","caller":"aigrammar/main.go:133","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2024-08-01T18:56:35.139+0800","caller":"aigrammar/main.go:148","func":"main.parseToken","msg":"claims: ","claims":{"deviceID":"12345ABC","gid":10001,"exp1":1727974853}} -{"level":"info","time":"2024-08-01T18:56:35.140+0800","caller":"aigrammar/translate.go:153","func":"main.TranslateFeedBackHandler","msg":"feedback","ID":10001,"feedback":{"product":"trans","input":"This is a demo text with more complex grammar checking algorithm of the pro version. ","output":"","res":"good"}} -{"level":"info","time":"2025-01-18T19:42:46.477+0800","caller":"aigrammar/main.go:48","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2025-01-18T19:43:20.350+0800","caller":"aigrammar/main.go:140","func":"main.parseToken","msg":"into func"} -{"level":"fatal","time":"2025-01-18T19:43:20.355+0800","caller":"aigrammar/main.go:150","func":"main.parseToken","msg":"ParaseToken Error.","error":"signature is invalid","stacktrace":"main.parseToken\n\t/root/aigrammar/main.go:150\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:227\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"info","time":"2025-01-18T19:48:25.208+0800","caller":"aigrammar/main.go:48","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2025-01-18T19:49:54.283+0800","caller":"aigrammar/main.go:140","func":"main.parseToken","msg":"into func"} -{"level":"fatal","time":"2025-01-18T19:49:54.288+0800","caller":"aigrammar/main.go:150","func":"main.parseToken","msg":"ParaseToken Error.","error":"signature is invalid","stacktrace":"main.parseToken\n\t/root/aigrammar/main.go:150\ngithub.com/labstack/echo-jwt/v4.Config.ToMiddleware.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo-jwt/v4@v4.2.0/jwt.go:227\ngithub.com/labstack/echo/v4.(*Echo).add.func1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:587\nmain.unifiedResponseHandler.func1\n\t/root/aigrammar/format.go:19\nmain.main.Recover.RecoverWithConfig.func2.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/recover.go:130\ngithub.com/labstack/echo/v4/middleware.RequestLoggerConfig.ToMiddleware.func1.1\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/middleware/request_logger.go:286\ngithub.com/labstack/echo/v4.(*Echo).ServeHTTP\n\t/root/go/pkg/mod/github.com/labstack/echo/v4@v4.12.0/echo.go:674\nnet/http.serverHandler.ServeHTTP\n\t/usr/local/go/src/net/http/server.go:3137\nnet/http.(*conn).serve\n\t/usr/local/go/src/net/http/server.go:2039"} -{"level":"info","time":"2025-01-18T19:56:22.182+0800","caller":"aigrammar/main.go:48","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"172.18.0.3:3306"} -{"level":"debug","time":"2025-01-18T19:56:29.911+0800","caller":"aigrammar/main.go:140","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2025-01-18T19:56:29.916+0800","caller":"aigrammar/main.go:155","func":"main.parseToken","msg":"claims: ","GID":10001,"DeviceID":"12345ABC","Exp1":1737201299} -{"level":"debug","time":"2025-01-18T20:00:25.259+0800","caller":"aigrammar/main.go:140","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2025-01-18T20:00:25.260+0800","caller":"aigrammar/main.go:155","func":"main.parseToken","msg":"claims: ","GID":10001,"DeviceID":"12345ABC","Exp1":1737201299} -{"level":"debug","time":"2025-01-18T20:02:30.579+0800","caller":"aigrammar/main.go:140","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2025-01-18T20:02:30.579+0800","caller":"aigrammar/main.go:155","func":"main.parseToken","msg":"claims: ","GID":10001,"DeviceID":"12345ABC","Exp1":1747201724} -{"level":"warn","time":"2025-01-18T20:02:30.615+0800","caller":"aigrammar/user.go:59","func":"main.queryUserHandler","msg":"userid not match","ID":10003,"userGID":10001} -{"level":"debug","time":"2025-01-18T20:04:37.741+0800","caller":"aigrammar/main.go:140","func":"main.parseToken","msg":"into func"} -{"level":"info","time":"2025-01-18T20:04:37.742+0800","caller":"aigrammar/main.go:155","func":"main.parseToken","msg":"claims: ","GID":10001,"DeviceID":"12345ABC","Exp1":1747201724} -{"level":"debug","time":"2025-01-18T20:04:37.764+0800","caller":"aigrammar/user.go:154","func":"main.queryUserBenefits","msg":"CheckAndDecrement","ID":10001,"timeZone":"Asia/Shanghai","secondsFromGMT":28800,"status":0} -{"level":"warn","time":"2025-01-18T20:04:44.317+0800","caller":"aigrammar/translate.go:243","func":"main.gTranslate","msg":"filterd","Hate":"safe","Hate-filtered":false,"SelfHarm":"safe","SelfHarm-filtered":false,"Sexual":"safe","Sexual-filtered":false,"Violence":"safe","Violence-filtered":false,"Error":"no content","input":"This is a demo text with more complex grammar checking algorithm of the pro version. This app have been designed to help you to write correctly and appear more professional. I work really hard to make this app as god as possible. If you are happy with the results, please consider supporting the app by subscribing to the PRO plan. The text writen here is to show you how much the app is capable of with the pro version. is this something you would like to use?"} -{"level":"debug","time":"2025-01-18T20:04:44.318+0800","caller":"aigrammar/translate.go:262","func":"main.gTranslate","msg":"Finish Reason","index":0,"reason":"stop"} -{"level":"info","time":"2025-01-18T20:04:44.318+0800","caller":"aigrammar/translate.go:48","func":"main.TranslateHandler","msg":"translation","ID":10001,"input":"This is a demo text with more complex grammar checking algorithm of the pro version. This app have been designed to help you to write correctly and appear more professional. I work really hard to make this app as god as possible. If you are happy with the results, please consider supporting the app by subscribing to the PRO plan. The text writen here is to show you how much the app is capable of with the pro version. is this something you would like to use?","output":"这是一个演示文本,它使用了更复杂的语法检查算法。这款应用程序的设计是为了帮助您进行正确地写作,以显得更加专业。我非常努力地使这款应用尽可能地完美。如果您对结果满意,请考虑通过订阅PRO计划来支持这款应用。这里写下的文本是为了向您展示这款应用在专业版本中所能达到的效果。这是您想要使用的吗?"} -{"level":"info","time":"2025-03-12T16:00:15.593+0800","caller":"aigrammar/main.go:48","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"testdb:3306"} -{"level":"info","time":"2025-03-12T16:00:46.611+0800","caller":"aigrammar/main.go:48","func":"main.main","msg":"DBManager init successfully. Mysql ","mysql_conn":"testdb:3306"} diff --git a/logs/echo.log b/logs/echo.log deleted file mode 100644 index 230190d..0000000 --- a/logs/echo.log +++ /dev/null @@ -1,71 +0,0 @@ -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-01T19:05:10+08:00","uri":"/pub/iap/callback","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-01T19:24:23+08:00","uri":"/pub/iap/callback","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-01T19:24:38+08:00","uri":"/internal/iap/history","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-02T16:48:49+08:00","uri":"/iap/verify","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-02T16:54:57+08:00","uri":"/iap/verify","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":500,"time":"2024-07-02T17:20:21+08:00","uri":"/iap/verify","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-02T17:24:08+08:00","uri":"/pub/iap/callback","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-02T17:29:08+08:00","uri":"/pub/iap/callback","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-02T17:30:30+08:00","uri":"/pub/iap/callback","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-02T17:37:40+08:00","uri":"/grammar/feedback","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":500,"time":"2024-07-02T18:21:48+08:00","uri":"/iap/verify","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":500,"time":"2024-07-02T18:22:29+08:00","uri":"/iap/verify","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-03T11:52:24+08:00","uri":"/iap/verify","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-03T11:53:23+08:00","uri":"/iap/verify","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-03T18:29:58+08:00","uri":"/user/get","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":500,"time":"2024-07-04T08:46:11+08:00","uri":"/user/get","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":500,"time":"2024-07-04T09:03:49+08:00","uri":"/user/get","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T09:05:34+08:00","uri":"/user/get","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T09:12:22+08:00","uri":"/user/get","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T09:36:49+08:00","uri":"/user/get","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T11:10:46+08:00","uri":"/iap/verify","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:15:31+08:00","uri":"/user/get","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:21:29+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:21:33+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:24:02+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:24:02+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:26:46+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:26:48+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:29:29+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:29:31+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:32:41+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:32:43+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:37:03+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:37:04+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:39:05+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:39:05+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:42:24+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:42:25+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:45:15+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:45:16+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:48:36+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:48:37+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:51:16+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:51:18+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:53:33+08:00","uri":"/user/get","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:54:18+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:54:19+08:00","uri":"/iap/verify","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T17:57:38+08:00","uri":"/user/get","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T19:07:40+08:00","uri":"/grammar/translate","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T19:08:08+08:00","uri":"/grammar/grammar","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-04T19:10:37+08:00","uri":"/grammar/words","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T08:37:44+08:00","uri":"/user/get","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T08:50:41+08:00","uri":"/grammar/grammar","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T08:56:16+08:00","uri":"/grammar/grammar","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T08:58:28+08:00","uri":"/grammar/words","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T08:59:33+08:00","uri":"/grammar/translate","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"GET","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T09:03:06+08:00","uri":"/internal/user/rights","user_agent":""} -{"level":"info","method":"GET","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T09:05:35+08:00","uri":"/internal/user/rights?ID=10004","user_agent":""} -{"level":"fatal","msg":"Failed to start server{error 26 0 listen tcp :80: bind: address already in use}","time":"2024-07-05T09:32:29+08:00"} -{"level":"info","method":"GET","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T09:33:56+08:00","uri":"/internal/user/rights/reset?ID=10004","user_agent":""} -{"level":"info","method":"GET","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T09:34:05+08:00","uri":"/internal/user/rights?ID=10004","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T09:34:14+08:00","uri":"/grammar/translate","user_agent":"AIGrammar/1.0 (com.easyprompts.aigrammar; build:1; iOS 16.7.8) Alamofire/5.9.1"} -{"level":"info","method":"GET","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-07-05T09:45:11+08:00","uri":"/internal/user/rights?ID=10004","user_agent":""} -{"level":"info","method":"GET","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-08-01T17:49:18+08:00","uri":"/internal/user/rights?ID=10004","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-08-01T17:49:38+08:00","uri":"/grammar/words","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-08-01T18:56:25+08:00","uri":"/grammar/words","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"192.168.65.1","status":200,"time":"2024-08-01T18:56:35+08:00","uri":"/grammar/feedback","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"172.18.0.1","status":401,"time":"2025-01-18T19:56:29+08:00","uri":"/user/get","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"172.18.0.1","status":401,"time":"2025-01-18T20:00:25+08:00","uri":"/user/get","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"172.18.0.1","status":200,"time":"2025-01-18T20:02:30+08:00","uri":"/user/get","user_agent":""} -{"level":"info","method":"POST","msg":"request log","remote_ip":"172.18.0.1","status":200,"time":"2025-01-18T20:04:44+08:00","uri":"/grammar/translate","user_agent":""} diff --git a/service.sh b/service.sh deleted file mode 100644 index a355d1d..0000000 --- a/service.sh +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/bash - -# 确保脚本使用一个参数 -if [ $# -ne 1 ]; then - echo "Usage: $0 {start|stop|restart}" - exit 1 -fi - -# 定义程序的目录路径 -program_dir="/usr/local/aigrammar" -program_name="aigrammar" -log_file="output.log" - -case "$1" in - start) - echo "Starting $program_name..." - cd $program_dir - nohup ./$program_name > $log_file 2>&1 & - echo "$program_name started." - ;; - stop) - echo "Stopping $program_name..." - killall $program_name - echo "$program_name stopped." - ;; - restart) - echo "Restarting $program_name..." - killall $program_name - sleep 2 - cd $program_dir - nohup ./$program_name > $log_file 2>&1 & - echo "$program_name restarted." - ;; - *) - echo "Unknown command: $1" - echo "Usage: $0 {start|stop|restart}" - exit 1 - ;; -esac diff --git a/comm.go b/src/comm.go similarity index 100% rename from comm.go rename to src/comm.go diff --git a/config.go b/src/config.go similarity index 96% rename from config.go rename to src/config.go index 156d9bf..886c7eb 100644 --- a/config.go +++ b/src/config.go @@ -61,16 +61,13 @@ var initError error func GetConfigManager() (*ConfigManager, error) { once.Do(func() { instance = &ConfigManager{} - initError = instance.initConfig() + // initError = instance.initConfig(configFile) }) return instance, initError } -func (cm *ConfigManager) initConfig() error { - viper.SetConfigName("config") - viper.SetConfigType("toml") - viper.AddConfigPath(".") - +func (cm *ConfigManager) initConfig(configFile string) error { + viper.SetConfigFile(configFile) if err := viper.ReadInConfig(); err != nil { return err } diff --git a/db.go b/src/db.go similarity index 100% rename from db.go rename to src/db.go diff --git a/errcode.go b/src/errcode.go similarity index 100% rename from errcode.go rename to src/errcode.go diff --git a/format.go b/src/format.go similarity index 100% rename from format.go rename to src/format.go diff --git a/iap.go b/src/iap.go similarity index 100% rename from iap.go rename to src/iap.go diff --git a/iap_def.go b/src/iap_def.go similarity index 100% rename from iap_def.go rename to src/iap_def.go diff --git a/iap_notify_v2.go b/src/iap_notify_v2.go similarity index 100% rename from iap_notify_v2.go rename to src/iap_notify_v2.go diff --git a/iap_notify_v2_types.go b/src/iap_notify_v2_types.go similarity index 100% rename from iap_notify_v2_types.go rename to src/iap_notify_v2_types.go diff --git a/logger.go b/src/logger.go similarity index 100% rename from logger.go rename to src/logger.go diff --git a/main.go b/src/main.go similarity index 93% rename from main.go rename to src/main.go index b6bf216..d1e4c32 100644 --- a/main.go +++ b/src/main.go @@ -15,12 +15,17 @@ import ( "github.com/natefinch/lumberjack" "github.com/sirupsen/logrus" "go.uber.org/zap" + "github.com/spf13/pflag" ) // 私有变量,只能在main包内访问 var jwtSigningKey []byte func main() { + // 使用 pflag 解析命令行参数 + configFile := pflag.String("config", "../conf/config.toml", "Path to the configuration file") + pflag.Parse() + //检查时区配置,需要包含东八区 _, err := time.LoadLocation(KEY_LOCAL_TIMEZONE) if err != nil { @@ -35,6 +40,12 @@ func main() { os.Exit(1) // Exit the program with an error code } + errconf := configManager.initConfig(*configFile) + if errconf != nil { + fmt.Fprintf(os.Stderr, "Failed to load config: %v\n", errconf) + os.Exit(1) // Exit the program with an error code + } + logconfig := configManager.GetLogConfig() initLogger(logconfig.LogFile, logconfig.MaxSize, logconfig.MaxBackups, logconfig.MaxAge, logconfig.Compress, logconfig.Level) // 初始化全局日志 defer logger.Sync() // 刷到磁盘 diff --git a/prompts.go b/src/prompts.go similarity index 100% rename from prompts.go rename to src/prompts.go diff --git a/translate.go b/src/translate.go similarity index 100% rename from translate.go rename to src/translate.go diff --git a/user.go b/src/user.go similarity index 100% rename from user.go rename to src/user.go diff --git a/userBenefits.go b/src/userBenefits.go similarity index 100% rename from userBenefits.go rename to src/userBenefits.go