This may be borderline for this site, but here goes: What you are looking for may be the notion of weak derivative. A function $f$ defined on some $d$-dimensional set $\Omega$ has a weak partial derivative with respect to the $i$-th coordinate if there exists a function $g_i$ ifsuch that for all smooth functions $\phi$ with compact support in $\Omega$ it holds that $$ \int_\Omega f(x)\partial_i \phi(x) dx = -\int_\Omega g_i(x)\phi(x)dx $$$$ \int_\Omega f(x)\partial_i \phi(x) dx = -\int_\Omega g_i(x)\phi(x)dx. $$ So thisThis looks very much like the distributional derivative and in fact one can say that $f$ has weak partial derivatives if the respective distributional derivatives are can be identified with locally integrable functions.
Similarly, you can define other differentiabledifferential operators: A locally integrable (vector-valued) function $\vec g$ is a weak gradient of $f$ if for all vector valued smooth functionfunctions $\vec \phi$ with compact support it holds that $$ \int_\Omega f(x)\operatorname{div}\vec\phi(x) dx = -\int_\Omega \vec g(x)\cdot\vec\phi(x)dx $$ and so on.
However, this is still not satisfying, since you need a certain notion of integral over the boundary of merely integrable functions. The theory you are looking for is the theory of Sobolev spaces and their traces. For the boundary integrals you may even want to consider integrals with respect to the Hausdorff measure. One reference is the book "Geometric integration theory" by Krantz and Parks.