---@meta cjson.safe

--------------------------------------------------------------------------------
-- lua-cjson safe C module
--------------------------------------------------------------------------------

---@class cjson_safe*: cjson*
---@type cjson_safe*
local M = {}

--- Create a new cjson.safe module table that is configured independently.
---@return cjson_safe* module New module table
function M.new() end

--- Guard-encoded Lua values to JSON.
---@param value any Lua value
---@return string? json JSON text
---@return string? errMsg error message
function M.encode(value) end

--- Protected decoding of JSON text.
---@param json string JSON text
---@return any value Lua value
---@return string? errMsg error message
function M.decode(json) end

return M
