Search code examples
phptwitterautomationtwitter-card

What is a Twitter Card URL?


[Please see update below original question]

I have created a Twitter Card. I can tweet it using the functionality built into the developer environment, but I wonder if I can just tweet using it from other environments. I want to somehow automate it.

I don't really want to write a web page, add it to a Word Press site, or anything like that.

Ideally, I'd like just tweet:

"Some test that is being tweeted [URL of Twitter Card]"

... and that would display the text, and the Twitter Card given by the URL.

Can you do this? The key (I guess) is finding the URL of a Twitter Card.

Failing that, can you use PHP to generate a Twitter Card, and tweet that? I could manage that, but would be simpler just to get the Twitter Card URL.

[Update] I asked this question from a position of not understanding the purpose of a Twitter card and how it works.

In fact, the process is pretty easy and once you understand the underlying philosophy, the solution is easy. Essentially, you set up meta data in the URL, in a given web page (you can test that it is working through a Twitter tool). When Twitter displays that URL, it uses the meta data to display the relevant image.

Here are a couple of URL's that I found to be useful:

  1. [Getting started with Twitter Cards][1]
  2. [Everything you need to know about Twitter Cards][2]

Hope this helps, and thank you to everybody that helped me.


Solution

  • Twitter Cards are, essentially, fancy links to specific web pages generated from data in those pages.

    Twitter Cards do not have their own URLs. The URL is just the URL to the web page the card is associated with.

    You need a web page.

    That web page could be generated from PHP.