Is there an option to pull metadata on urn:li[pivot][code]












0















I'm using the endpoint 'adAnalyticsV2' and when applying a pivot to the request I get a field named 'pivotvalue' and in the case of the pivot of: 'MEMBER_INDUSTRY'.



An example of a value in the 'pivotvalue' field is: 'urn:li:industry:50' Documentation here: https://developer.linkedin.com/docs/guide/v2/ads/ads-reporting



Is it possible to pull metadata about the 'urn:li:industry:50' value?



Looking at the reference table here: https://developer.linkedin.com/docs/reference/industry-codes I can discern that an Industry Code of 50 is 'Architecture & Planning'.



Is there a way to get this value from the adAnalyticsV2 endpoint?



My current solution is basically to copy the reference table and do a mapping to my data which is very clunky.










share|improve this question





























    0















    I'm using the endpoint 'adAnalyticsV2' and when applying a pivot to the request I get a field named 'pivotvalue' and in the case of the pivot of: 'MEMBER_INDUSTRY'.



    An example of a value in the 'pivotvalue' field is: 'urn:li:industry:50' Documentation here: https://developer.linkedin.com/docs/guide/v2/ads/ads-reporting



    Is it possible to pull metadata about the 'urn:li:industry:50' value?



    Looking at the reference table here: https://developer.linkedin.com/docs/reference/industry-codes I can discern that an Industry Code of 50 is 'Architecture & Planning'.



    Is there a way to get this value from the adAnalyticsV2 endpoint?



    My current solution is basically to copy the reference table and do a mapping to my data which is very clunky.










    share|improve this question



























      0












      0








      0


      1






      I'm using the endpoint 'adAnalyticsV2' and when applying a pivot to the request I get a field named 'pivotvalue' and in the case of the pivot of: 'MEMBER_INDUSTRY'.



      An example of a value in the 'pivotvalue' field is: 'urn:li:industry:50' Documentation here: https://developer.linkedin.com/docs/guide/v2/ads/ads-reporting



      Is it possible to pull metadata about the 'urn:li:industry:50' value?



      Looking at the reference table here: https://developer.linkedin.com/docs/reference/industry-codes I can discern that an Industry Code of 50 is 'Architecture & Planning'.



      Is there a way to get this value from the adAnalyticsV2 endpoint?



      My current solution is basically to copy the reference table and do a mapping to my data which is very clunky.










      share|improve this question
















      I'm using the endpoint 'adAnalyticsV2' and when applying a pivot to the request I get a field named 'pivotvalue' and in the case of the pivot of: 'MEMBER_INDUSTRY'.



      An example of a value in the 'pivotvalue' field is: 'urn:li:industry:50' Documentation here: https://developer.linkedin.com/docs/guide/v2/ads/ads-reporting



      Is it possible to pull metadata about the 'urn:li:industry:50' value?



      Looking at the reference table here: https://developer.linkedin.com/docs/reference/industry-codes I can discern that an Industry Code of 50 is 'Architecture & Planning'.



      Is there a way to get this value from the adAnalyticsV2 endpoint?



      My current solution is basically to copy the reference table and do a mapping to my data which is very clunky.







      linkedin linkedin-api






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Jul 26 '18 at 0:22









      Pearly Spencer

      11.8k173965




      11.8k173965










      asked Jul 25 '18 at 20:13









      Zach CoxZach Cox

      63




      63
























          3 Answers
          3






          active

          oldest

          votes


















          0














          We have the same issue :(



          It's actually not possible to get all values because it's impossible to store all targeting options into our database (huge amount of members...companies...). We have tried using "Discover Targeting Options by URNs" (https://developer.linkedin.com/docs/guide/v2/ads/ads-targeting1#entities4) but we always get an error (only for this endpoint).



          @LinkedinDevelopers - It would be more elegant if we get more metadata for pivot values.



          Regards, Aleksander






          share|improve this answer
























          • This does not provide an answer for the question. You should move it into comment section.

            – Tommy
            Sep 1 '18 at 0:28



















          0














          I found one option using response decoration (https://developer.linkedin.com/docs/guide/v2/concepts/decoration), but it's not working for all pivots*.



          Try adding



          projection=(*,elements(*(*,pivotValue~(*))))


          or (for multiple pivots)



          projection=(*,elements*(*,pivotValues(*~(*))))


          You will get metadata for that pivotValue.
          I have tested all pivots and get errors for pivots* bellow:




          • CAMPAIGN_GROUP -> Unsupported URN domain: li:sponsoredCampaignGroup

          • CREATIVE -> Downstream service returned an empty response for URN

          • CONVERSION -> Unsupported URN domain:
            lla:llaPartnerConversion

          • SERVING_LOCATION -> Malformed URN link:ON_SITE


          • MEMBER_COMPANY_SIZE -> Malformed URN link: SIZE_11_TO_50


          • MEMBER_COUNTRY -> Not enough permissions to access: GET /countriesV2


          Other pivotValues seems to be fine.



          Regards, Aleksander






          share|improve this answer

































            0














            What I ended up doing is parsing the ids out of the pivotValues, get all of the industries for the endpoint:
            https://api.linkedin.com/v2/industries, and then mapping the industry names from the response to the ids.






            share|improve this answer























              Your Answer






              StackExchange.ifUsing("editor", function () {
              StackExchange.using("externalEditor", function () {
              StackExchange.using("snippets", function () {
              StackExchange.snippets.init();
              });
              });
              }, "code-snippets");

              StackExchange.ready(function() {
              var channelOptions = {
              tags: "".split(" "),
              id: "1"
              };
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function() {
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled) {
              StackExchange.using("snippets", function() {
              createEditor();
              });
              }
              else {
              createEditor();
              }
              });

              function createEditor() {
              StackExchange.prepareEditor({
              heartbeatType: 'answer',
              autoActivateHeartbeat: false,
              convertImagesToLinks: true,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: 10,
              bindNavPrevention: true,
              postfix: "",
              imageUploader: {
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              },
              onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              });


              }
              });














              draft saved

              draft discarded


















              StackExchange.ready(
              function () {
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f51526982%2fis-there-an-option-to-pull-metadata-on-urnlipivotcode%23new-answer', 'question_page');
              }
              );

              Post as a guest















              Required, but never shown

























              3 Answers
              3






              active

              oldest

              votes








              3 Answers
              3






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes









              0














              We have the same issue :(



              It's actually not possible to get all values because it's impossible to store all targeting options into our database (huge amount of members...companies...). We have tried using "Discover Targeting Options by URNs" (https://developer.linkedin.com/docs/guide/v2/ads/ads-targeting1#entities4) but we always get an error (only for this endpoint).



              @LinkedinDevelopers - It would be more elegant if we get more metadata for pivot values.



              Regards, Aleksander






              share|improve this answer
























              • This does not provide an answer for the question. You should move it into comment section.

                – Tommy
                Sep 1 '18 at 0:28
















              0














              We have the same issue :(



              It's actually not possible to get all values because it's impossible to store all targeting options into our database (huge amount of members...companies...). We have tried using "Discover Targeting Options by URNs" (https://developer.linkedin.com/docs/guide/v2/ads/ads-targeting1#entities4) but we always get an error (only for this endpoint).



              @LinkedinDevelopers - It would be more elegant if we get more metadata for pivot values.



              Regards, Aleksander






              share|improve this answer
























              • This does not provide an answer for the question. You should move it into comment section.

                – Tommy
                Sep 1 '18 at 0:28














              0












              0








              0







              We have the same issue :(



              It's actually not possible to get all values because it's impossible to store all targeting options into our database (huge amount of members...companies...). We have tried using "Discover Targeting Options by URNs" (https://developer.linkedin.com/docs/guide/v2/ads/ads-targeting1#entities4) but we always get an error (only for this endpoint).



              @LinkedinDevelopers - It would be more elegant if we get more metadata for pivot values.



              Regards, Aleksander






              share|improve this answer













              We have the same issue :(



              It's actually not possible to get all values because it's impossible to store all targeting options into our database (huge amount of members...companies...). We have tried using "Discover Targeting Options by URNs" (https://developer.linkedin.com/docs/guide/v2/ads/ads-targeting1#entities4) but we always get an error (only for this endpoint).



              @LinkedinDevelopers - It would be more elegant if we get more metadata for pivot values.



              Regards, Aleksander







              share|improve this answer












              share|improve this answer



              share|improve this answer










              answered Aug 3 '18 at 15:08









              Aleksander JančičAleksander Jančič

              12




              12













              • This does not provide an answer for the question. You should move it into comment section.

                – Tommy
                Sep 1 '18 at 0:28



















              • This does not provide an answer for the question. You should move it into comment section.

                – Tommy
                Sep 1 '18 at 0:28

















              This does not provide an answer for the question. You should move it into comment section.

              – Tommy
              Sep 1 '18 at 0:28





              This does not provide an answer for the question. You should move it into comment section.

              – Tommy
              Sep 1 '18 at 0:28













              0














              I found one option using response decoration (https://developer.linkedin.com/docs/guide/v2/concepts/decoration), but it's not working for all pivots*.



              Try adding



              projection=(*,elements(*(*,pivotValue~(*))))


              or (for multiple pivots)



              projection=(*,elements*(*,pivotValues(*~(*))))


              You will get metadata for that pivotValue.
              I have tested all pivots and get errors for pivots* bellow:




              • CAMPAIGN_GROUP -> Unsupported URN domain: li:sponsoredCampaignGroup

              • CREATIVE -> Downstream service returned an empty response for URN

              • CONVERSION -> Unsupported URN domain:
                lla:llaPartnerConversion

              • SERVING_LOCATION -> Malformed URN link:ON_SITE


              • MEMBER_COMPANY_SIZE -> Malformed URN link: SIZE_11_TO_50


              • MEMBER_COUNTRY -> Not enough permissions to access: GET /countriesV2


              Other pivotValues seems to be fine.



              Regards, Aleksander






              share|improve this answer






























                0














                I found one option using response decoration (https://developer.linkedin.com/docs/guide/v2/concepts/decoration), but it's not working for all pivots*.



                Try adding



                projection=(*,elements(*(*,pivotValue~(*))))


                or (for multiple pivots)



                projection=(*,elements*(*,pivotValues(*~(*))))


                You will get metadata for that pivotValue.
                I have tested all pivots and get errors for pivots* bellow:




                • CAMPAIGN_GROUP -> Unsupported URN domain: li:sponsoredCampaignGroup

                • CREATIVE -> Downstream service returned an empty response for URN

                • CONVERSION -> Unsupported URN domain:
                  lla:llaPartnerConversion

                • SERVING_LOCATION -> Malformed URN link:ON_SITE


                • MEMBER_COMPANY_SIZE -> Malformed URN link: SIZE_11_TO_50


                • MEMBER_COUNTRY -> Not enough permissions to access: GET /countriesV2


                Other pivotValues seems to be fine.



                Regards, Aleksander






                share|improve this answer




























                  0












                  0








                  0







                  I found one option using response decoration (https://developer.linkedin.com/docs/guide/v2/concepts/decoration), but it's not working for all pivots*.



                  Try adding



                  projection=(*,elements(*(*,pivotValue~(*))))


                  or (for multiple pivots)



                  projection=(*,elements*(*,pivotValues(*~(*))))


                  You will get metadata for that pivotValue.
                  I have tested all pivots and get errors for pivots* bellow:




                  • CAMPAIGN_GROUP -> Unsupported URN domain: li:sponsoredCampaignGroup

                  • CREATIVE -> Downstream service returned an empty response for URN

                  • CONVERSION -> Unsupported URN domain:
                    lla:llaPartnerConversion

                  • SERVING_LOCATION -> Malformed URN link:ON_SITE


                  • MEMBER_COMPANY_SIZE -> Malformed URN link: SIZE_11_TO_50


                  • MEMBER_COUNTRY -> Not enough permissions to access: GET /countriesV2


                  Other pivotValues seems to be fine.



                  Regards, Aleksander






                  share|improve this answer















                  I found one option using response decoration (https://developer.linkedin.com/docs/guide/v2/concepts/decoration), but it's not working for all pivots*.



                  Try adding



                  projection=(*,elements(*(*,pivotValue~(*))))


                  or (for multiple pivots)



                  projection=(*,elements*(*,pivotValues(*~(*))))


                  You will get metadata for that pivotValue.
                  I have tested all pivots and get errors for pivots* bellow:




                  • CAMPAIGN_GROUP -> Unsupported URN domain: li:sponsoredCampaignGroup

                  • CREATIVE -> Downstream service returned an empty response for URN

                  • CONVERSION -> Unsupported URN domain:
                    lla:llaPartnerConversion

                  • SERVING_LOCATION -> Malformed URN link:ON_SITE


                  • MEMBER_COMPANY_SIZE -> Malformed URN link: SIZE_11_TO_50


                  • MEMBER_COUNTRY -> Not enough permissions to access: GET /countriesV2


                  Other pivotValues seems to be fine.



                  Regards, Aleksander







                  share|improve this answer














                  share|improve this answer



                  share|improve this answer








                  edited Aug 23 '18 at 8:54

























                  answered Aug 22 '18 at 13:04









                  Aleksander JančičAleksander Jančič

                  12




                  12























                      0














                      What I ended up doing is parsing the ids out of the pivotValues, get all of the industries for the endpoint:
                      https://api.linkedin.com/v2/industries, and then mapping the industry names from the response to the ids.






                      share|improve this answer




























                        0














                        What I ended up doing is parsing the ids out of the pivotValues, get all of the industries for the endpoint:
                        https://api.linkedin.com/v2/industries, and then mapping the industry names from the response to the ids.






                        share|improve this answer


























                          0












                          0








                          0







                          What I ended up doing is parsing the ids out of the pivotValues, get all of the industries for the endpoint:
                          https://api.linkedin.com/v2/industries, and then mapping the industry names from the response to the ids.






                          share|improve this answer













                          What I ended up doing is parsing the ids out of the pivotValues, get all of the industries for the endpoint:
                          https://api.linkedin.com/v2/industries, and then mapping the industry names from the response to the ids.







                          share|improve this answer












                          share|improve this answer



                          share|improve this answer










                          answered Nov 15 '18 at 19:43









                          Zach CoxZach Cox

                          63




                          63






























                              draft saved

                              draft discarded




















































                              Thanks for contributing an answer to Stack Overflow!


                              • Please be sure to answer the question. Provide details and share your research!

                              But avoid



                              • Asking for help, clarification, or responding to other answers.

                              • Making statements based on opinion; back them up with references or personal experience.


                              To learn more, see our tips on writing great answers.




                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function () {
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f51526982%2fis-there-an-option-to-pull-metadata-on-urnlipivotcode%23new-answer', 'question_page');
                              }
                              );

                              Post as a guest















                              Required, but never shown





















































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown

































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown







                              Popular posts from this blog

                              Bressuire

                              Vorschmack

                              Quarantine