def METHOD_NAME() -> Plugin:
    return Plugin(
        start=False,
        spec=Spec(
            module=__name__,
            className='ContainsPatternAction',
            inputs=["payload"],
            outputs=["true", "false"],
            version='0.7.2',
            license="MIT",
            author="Mateusz Zitaruk",
            init={
                "field": None,
                "pattern": None
            },
            manual="contains_pattern_action",
            form=Form(
                groups=[
                    FormGroup(
                        name="Field contains pattern plugin configuration",
                        fields=[
                            FormField(
                                id="field",
                                name="Type string or path to string that you want to check.",
                                component=FormComponent(
                                    type="dotPath",
                                    props={
                                        "label": "Path",
                                        "defaultSourceValue": "event"
                                    }
                                )
                            ),
                            FormField(
                                id="pattern",
                                name="Pattern",
                                description="Type pattern to check if data field contains it.",
                                component=FormComponent(
                                    type="select",
                                    props={
                                        "label": "Pattern", "items": {
                                            "all": "all",
                                            "email": "email",
                                            "url": "url",
                                            "ip": "ip",
                                            "date": "date"
                                        }
                                    }
                                )
                            )
                        ]
                    )
                ]
            )
        ),
        metadata=MetaData(
            name='Contains pattern',
            desc='Checks if field contains defined pattern.',
            icon='exists',
            group=["String"],
            purpose=['collection', 'segmentation'],
            documentation=Documentation(
                inputs={
                    "payload": PortDoc(desc="This port takes payload object.")
                },
                outputs={"true": PortDoc(desc="This port returns new object if field contains defined pattern."),
                         "false":
                             PortDoc(desc="This port returns payload if field doesn't contain defined pattern.")}
            )
        )
    )