定制 orangecat/viewlog 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

orangecat/viewlog

最新稳定版本:1.0.1

Composer 安装命令:

composer require orangecat/viewlog

包简介

Orangecat ViewLog Module

README 文档

README

This module provides logging capabilities for GraphQL and REST API requests in Magento 2. It allows administrators to view detailed logs of API interactions, including request parameters, responses, and status codes.

Features

  • GraphQL Logging: Captures GraphQL queries, variables, responses, and execution times.
  • REST Logging: Captures REST API endpoints, request data, responses, and execution times.
  • Admin Interface: dedicated grids to view and filter logs.
  • Auto-Cleanup: Configurable retention period with automatic pruning via cron.

Installation

Install via composer:

composer require orangecat/viewlog
php bin/magento module:enable Orangecat_ViewLog
php bin/magento setup:upgrade

Configuration

Configuration is available under Stores > Configuration > Services > Magento Web API.

Graphql Logger Settings

  • Enable Graphql Logger: Turn GraphQL logging on/off.
  • Retention Days (Graphql): Number of days to keep logs before automatic deletion (Default: 30 days).

REST Logger Settings

  • Enable REST Logger: Turn REST logging on/off.
  • Retention Days (REST): Number of days to keep logs before automatic deletion (Default: 30 days).

Access

You can access the log viewers from the Admin Panel:

  1. GraphQL Logs: System > Tools > Graphql Logs
  2. REST Logs: System > Tools > REST Logs

Cron Jobs

The module includes a cron job that runs daily at 03:00 AM to clean up logs older than the configured retention period.

  • orangecat_graphqlviewlog_cleanup: Executes Orangecat\ViewLog\Cron\Cleanup::execute

Database Tables

  • orangecat_graphql_log: Stores GraphQL request logs.
  • orangecat_rest_log: Stores REST API request logs.

统计信息

  • 总下载量: 29
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 2
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 0
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: OSL-3.0
  • 更新时间: 2026-02-03

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固