some examples for document, document type and publishing a document
Your question is very vague.
Please review the webMethods online documentation (techcommunity.softwareag.com/ecosystem/documentation) for more info.
webMethods Developers user guide (documents,documentTypes)
webMethods TradingNetworks user guide (TN documentTypes/rules/actions)
Integration Server Built-in services user guide (pub.publish:publish)
webMethods Broker user guide (on publish/subscribe)