Figure out if you want the interaction to be on a target (ex. machine in the world) or on a source (item in hand, ex. welder, crowbar) which interacts with a different target. Once you have worked out if it is a target or source, create a class which implements IInteraction. The most important methods are going to be:
GetName: generates a display name
CanInteract: if the interaction is possible
Start: called when the interaction is started
You can access data about the interaction using the InteractionEvent parameter. I recommend looking at existing interactions for examples.
Add a script to the object. It should inherit from InteractionTargetBehaviour or InteractionTargetNetworkBehaviour, depending on if you want certain things to be networked. You will have to implement GenerateInteractions in your class. There you can return an array of the interactions on your object.
If you are creating an interaction which is only needed for a single kind of object, consider using a simple interaction. You can create it and assign callbacks which you can directly implement in your attached script.
The item component is the source of the interaction. To add more interactions, you can add a component which implements IInteractionSourceExtension.
Send Alainx277 or John a message on the discord, we'd be glad to help
Interactions are not inheriting from monobehaviour. This means that interactions are not components on an game object. Interactions are generated by an interaction target or interaction source, which both can be on game objects.
The fundamental parts of the system are the source, the target, and the interaction.
The source is used to perform the interaction. When holding nothing, it is the hands of the player. When an item is held it is the source. Sources are structured like a tree. A source can have a parent and you can traverse up, depending on what information you need. Right now the source structure is a maximum of 2 deep (hands an tools) but that might change.
The target is on what the interaction is performed, essentially what the player clicks. It can be anything from another player to a floor tile. There can be multiple targets per game object.
Interactions are created whenever the player wants to interact. This can happen in both the source and targets. They are essentially the results of interacting and modify the world. These interactions are always run on the server but there are also client interactions to show client only things.