{"action":"reopened","issue":{"url":"https://api.github.com/repos/ninelabs/atl-tech-meetups/issues/5","repository_url":"https://api.github.com/repos/ninelabs/atl-tech-meetups","labels_url":"https://api.github.com/repos/ninelabs/atl-tech-meetups/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/ninelabs/atl-tech-meetups/issues/5/comments","events_url":"https://api.github.com/repos/ninelabs/atl-tech-meetups/issues/5/events","html_url":"https://github.com/ninelabs/atl-tech-meetups/issues/5","id":296207459,"number":5,"title":"WP Job Manager post to Slack Notification","user":{"login":"jcornelius","id":366136,"avatar_url":"https://avatars3.githubusercontent.com/u/366136?v=4","gravatar_id":"","url":"https://api.github.com/users/jcornelius","html_url":"https://github.com/jcornelius","followers_url":"https://api.github.com/users/jcornelius/followers","following_url":"https://api.github.com/users/jcornelius/following{/other_user}","gists_url":"https://api.github.com/users/jcornelius/gists{/gist_id}","starred_url":"https://api.github.com/users/jcornelius/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jcornelius/subscriptions","organizations_url":"https://api.github.com/users/jcornelius/orgs","repos_url":"https://api.github.com/users/jcornelius/repos","events_url":"https://api.github.com/users/jcornelius/events{/privacy}","received_events_url":"https://api.github.com/users/jcornelius/received_events","type":"User","site_admin":false},"labels":[{"id":180591982,"url":"https://api.github.com/repos/ninelabs/atl-tech-meetups/labels/enhancement","name":"enhancement","color":"84b6eb","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-02-11T17:25:44Z","updated_at":"2018-02-16T01:23:18Z","closed_at":null,"author_association":"OWNER","body":"# Summary\r\nAs a user of tech404, I would like to have a notification of jobs posted to the job board appear in the appropriate channel in the tech404 Slack team.\r\n\r\n#### Technologies used\r\n- [WP Job Manager](https://github.com/Automattic/WP-Job-Manager) \r\n- [Slack API messages](https://api.slack.com/docs/messages)\r\n\r\n\r\n## Overview\r\nWe would like a notification posted to the appropriate channel when jobs are _successfully approved_ in WP Job Manager. Notifications should only be posted to Slack with a job is *approved*, not when submitted.\r\n\r\nThe Message should include:\r\n- Job type (in the message title)\r\n- The title of the job post, which links to the post on tech404. \r\n- Job description, truncated to 200 characters \r\n- Company name\r\n- Company logo\r\n- Job location\r\n\r\nHere's an example of the message payload that needs to be created for Slack.\r\n\r\n### Slack JSON Payload\r\n```\r\n{\r\n    \"attachments\": [\r\n        {\r\n            \"pretext\": \"New {{job_type}} Job posting!\",\r\n            \"color\": \"#36a64f\",\r\n            \"title\": \"{{job_title}}\",\r\n            \"title_link\": \"https://tech404.io/job/{{job_posting_slug}}\",\r\n            \"text\": \"{{job_description:truncate:200}}\",\r\n            \"thumb_url\": \"{{job_company_logo}}\",\r\n            \"fields\": [\r\n                  {\r\n                        \"title\": \"Company\",\r\n                        \"value\": \"{{job_company_name}}\",\r\n                        \"short\": true\r\n                  },\r\n                  {\r\n                        \"title\": \"Location\",\r\n                        \"value\": \"{{job_location}}\",\r\n                        \"short\": true\r\n                  }\r\n            ]\r\n        }\r\n    ]\r\n}\r\n```\r\n### Payload Example\r\n```\r\n{\r\n   \"attachments\": [\r\n      {\r\n            \"pretext\": \"New Full-time Job posting!\",\r\n            \"color\": \"#36a64f\",\r\n            \"title\": \"Sr. User Experience Designer\",\r\n            \"title_link\": \"https://tech404.io/job/slug-to-job-posting\",\r\n            \"text\": \"Terminus is a fast growing technology company in Atlanta, challenging the status quo of B2B marketing. We've built an industry-leading Account-Based Marketing (ABM) platform that enables our customers to be more targeted in reaching their ideal customers, driving powerful business outcomes including an increase in revenue and acceleration of pipeline velocity.\",\r\n            \"thumb_url\": \"https://tech404.io/wp-content/uploads/job-manager-uploads/company_logo/2018/02/terminus.png\",\r\n            \"fields\": [\r\n                  {\r\n                        \"title\": \"Company\",\r\n                        \"value\": \"Awesome Startup\",\r\n                        \"short\": true\r\n                  },\r\n                  {\r\n                        \"title\": \"Location\",\r\n                        \"value\": \"Atlanta, GA\",\r\n                        \"short\": true\r\n                  }\r\n            ]\r\n        }\r\n    ]\r\n}\r\n```\r\n\r\nThe resulting post in Slack should look like this:\r\n![screenshot 2018-02-11 12 09 42](https://user-images.githubusercontent.com/366136/36075995-82e01fe2-0f24-11e8-82da-144afc577572.png)\r\n\r\nAlso: see this [API Message Builder](https://api.slack.com/api_docs_message_builder.php?msg=%7B%22attachments%22%3A%5B%7B%22pretext%22%3A%22New%20Full-time%20Job%20posting!%22%2C%22color%22%3A%22%2336a64f%22%2C%22title%22%3A%22Sr.%20User%20Experience%20Designer%22%2C%22title_link%22%3A%22https%3A%2F%2Ftech404.io%2Fjob%2Fslug-to-job-posting%22%2C%22text%22%3A%22Terminus%20is%20a%20fast%20growing%20technology%20company%20in%20Atlanta%2C%20challenging%20the%20status%20quo%20of%20B2B%20marketing.%20We%27ve%20built%20an%20industry-leading%20Account-Based%20Marketing%20(ABM)%20platform%20that%20enables%20our%20customers%20to%20be%20more%20targeted%20in%20reaching%20their%20ideal%20customers%2C%20driving%20powerful%20business%20outcomes%20including%20an%20increase%20in%20revenue%20and%20acceleration%20of%20pipeline%20velocity.%22%2C%22thumb_url%22%3A%22https%3A%2F%2Ftech404.io%2Fwp-content%2Fuploads%2Fjob-manager-uploads%2Fcompany_logo%2F2018%2F02%2Fterminus.png%22%2C%22fields%22%3A%5B%7B%22title%22%3A%22Company%22%2C%22value%22%3A%22Awesome%20Startup%22%2C%22short%22%3Atrue%7D%2C%7B%22title%22%3A%22Location%22%2C%22value%22%3A%22Atlanta%2C%20GA%22%2C%22short%22%3Atrue%7D%5D%7D%5D%7D)\r\n\r\n\r\n### Job-type to Slack channel mapping\r\nThere are 5 job types supported by the WP Job Manager plugin on the tech404 website.\r\n1. Full-time\r\n2. Part-time\r\n3. Internship\r\n4. Temporary\r\n5. Freelance\r\n\r\nThere are currently three channels in the tech404 Slack team for job postings:\r\n1. #jobs\r\n2. #gigs\r\n3. #freelance\r\n\r\nJob types should be mapped to channels as follows:\r\n\r\n1. Full-time > #jobs\r\n2. Part-time > #jobs\r\n3. Internship > #gigs\r\n4. Temporary > #gigs\r\n5. Freelance > #freelance"}}
{"actor":{"display_login":"nicdev"}}