Example website-1

RDFa (source lint)

<div vocab="http://schema.org/" typeof="WebSite">
    <meta property="url" href="http://www.example.com/"/>
    <form property="potentialAction" typeof="http://schema.org/SearchAction">
      <meta property="target" content="http://www.example.com/search?q={query}"/>
      <input property="query-input" type="text" name="query">
      <input type="submit">
    </form>
</div>

microdata (source lint)

<div itemscope itemtype="http://schema.org/WebSite">
    <link itemprop="url" href="http://www.example.com/"/>
    <form itemprop="potentialAction" itemscope itemtype="http://schema.org/SearchAction">
	  <meta itemprop="target" content="http://example.com/search?q={query}"/>
      <input itemprop="query-input" type="text" name="query"/>
      <input type="submit"/>
    </form>
</div>

JSON-LD (source lint)

<script type="application/ld+json">
{
    "@context": "http://schema.org",
    "@type": "WebSite",
    "url": "http://example.com/",
    "potentialAction": {
      "@type": "SearchAction",
      "target": "http://example.com/search?&q={query}",
      "query-input": "required"
    }
}
</script>